This GitHub Action takes a directory, renames, archives and uploads it via rclone.
Create a workflow .yml
file in your repositories .github/workflows
directory. An example workflow is available below. For more information, reference the GitHub Help Documentation for Creating a workflow file.
bucket
- Upload destination, indest:full/path
format. Will be directly passed to rclonepublish_dir
- Directory to archiverelease_name
- Name of directory that groups all the project's releases and individual release archive base namerelease_tag
- (optional) Unique identifier that gets appended to the archive file name. Defaults to<tag-name>_<commit-short-sha>
where tags exist and<commit-short-sha>
for everything else.
release
- Full archive path on remote
name: Release
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Release
uses: andreiio/rclone-release@v1
with:
bucket: "s3:release"
publish_dir: ./public
release_name: project-name
env:
RCLONE_CONFIG_S3_TYPE: s3
RCLONE_CONFIG_S3_ACCESS_KEY_ID: ${{ secrets.ACCESS_KEY_ID }}
RCLONE_CONFIG_S3_SECRET_ACCESS_KEY: ${{ secrets.SECRET_ACCESS_KEY }}
See the rclone documentation on environment variables for info on remote access configuration.
The scripts and documentation in this project are released under the MIT License