github-release-backup

command module
v0.0.0-...-a8384db Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 7, 2021 License: MIT Imports: 10 Imported by: 0

README

github-release-backup

A minimal tool that backs up GitHub release assets to an S3 compatible backend. By default, GitHub actions will only host artifacts for a maximum of 90 days. This tool can be used to perform a one-time backup of all release assets.

Installation

go get github.com/mjpitz/github-release-backup

Usage

# github configuration
export GITHUB_OWNER="depscloud"
export GITHUB_REPO="depscloud"
export GITHUB_ACCESS_TOKEN="github_access_token" 

# s3 configuration
export S3_ENDPOINT="sfo2.digitaloceanspaces.com"  # configure the s3 endpoint
export S3_DISABLE_SSL=""                          # set to non-empty value to disable tls
export AWS_DEFAULT_REGION="region"
export AWS_ACCESS_KEY_ID="aws_access_key_id"
export AWS_SECRET_ACCESS_KEY="aws_secret_access_key"
export S3_BUCKET_NAME="bucket_name"

# configure existing asset behavior
export ON_EXISTING_ASSET="halt"      # stop when we encounter an asset that already exists
export ON_EXISTING_ASSET="overwrite" # overwrite assets that already exist
export ON_EXISTING_ASSET=""          # skip assets that already exist

# run the script
github-release-backup

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL