Fork from wei/rclone: Wraps the rclone CLI to be used in Github Actions
- This Action wraps rclone to enable syncing files and directories from github repository to backblaze B2 cloud storage bucket.
- All files exclude "/{.git,.github}/".
on: push
jobs:
rclone:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: <workflow_name>
uses: wjkbfq/rclone_b2@master
env:
RCLONE_CONF: ${{ secrets.RCLONE_CONF }}
with:
args: sync --exclude "/{.git,.github}/" ./ <storage_name>:<bucket_name>/
Key | Value | Type | Required |
---|---|---|---|
<workflow_name> | Workflow name | String | No |
<storage_name> | Storage name in RCLONE_CONF | String | Yes |
<bucket_name> | Storage bucket name | String | Yes |
Key | Value | Type | Required |
---|---|---|---|
RCLONE_CONF | Rclone configuration information | Secrets | Yes |
RCLONE_CONF
can be omitted if CLI arguments or environment variables are supplied. RCLONE_CONF
can also be encrypted if RCLONE_CONFIG_PASS
secret is supplied.
[<storage_name>]
type = b2
account = <applicationKey_ID>
key = <applicationKey>
hard_delete = true
docker run --rm -e "RCLONE_CONF=$(cat ~/.config/rclone/rclone.conf)" $(docker build -q .) \
sync --exclude "/{.git,.github}/" ./ <storage_name>:<bucket_name>/