git-s3-push

Deploy your git repo to an S3 bucket

Github星跟蹤圖

git-s3-push

Build Status
Go Report Card

git-s3-push is a tool to deploy git repositories to AWS S3 buckets. git-s3-push keeps track of which commits have been pushed and supports deploying only recently modified files.
It can be used for deploying static websites hosted on S3, maintaining versioned bucket data or using S3 to backup git repositories.

Features

  • Simple method to deploy git repos to S3.
  • Fast uploads by only uploading new commits.
  • Automatically detects and sets the S3 content type of files.
  • Can automatically make your files publicly available (private by default).
  • Single binary, no dependencies on language runtimes.

Installation

Grab a binary for your platform from the releases. Or check out the code, run go get and go run git-s3-push.go.

Git must be installed on your path.

Usage

Authentication credentials are taken from the standard AWS environment variables. Bucket name and AWS region are supplied as arguments.

$ export AWS_ACCESS_KEY_ID=<...>

$ export AWS_SECRET_ACCESS_KEY=<...>

$ git-s3-push -b my-bucket-name -r aws-region-1 -save

The -save flag stores the bucket name and region so you can push to the same location by just running:

$ git-s3-push

The -public flag can be used to make the files uploaded to your bucket publicly readable. When running without the -public flag, pushed files are stored privately.

All usage options can be shown using the -help flag.

Config

After using the -save flag, git-s3-push creates a JSON configuration file (.git_s3_push) storing bucket and region information. This file also includes other configuration directives that cannot be specified using flags:

  • Ignore: Files in the git repo that should not be pushed. This could include source files (for example .coffee files), or any other file in the git repository you don't want pushed to the S3 bucket. Files are specified in a JSON list of regexes. For example: "Ignore":["src/*.coffee"]

  • IncludeNonGit: Files not tracked by git that should be pushed to the destination bucket. Files are specified in a JSON list of paths. Paths can be absolute or relative to the root of the git repository.

License

  • MIT license. See the LICENSE file.

主要指標

概覽
名稱與所有者dmfutcher/git-s3-push
主編程語言Go
編程語言Go (語言數: 1)
平台
許可證MIT License
所有者活动
創建於2015-12-09 20:08:11
推送於2023-01-09 06:49:02
最后一次提交
發布數4
最新版本名稱0.2.1 (發布於 )
第一版名稱v0.1.0 (發布於 )
用户参与
星數222
關注者數13
派生數29
提交數54
已啟用問題?
問題數14
打開的問題數6
拉請求數4
打開的拉請求數2
關閉的拉請求數0
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?