31 lines
670 B
Markdown
31 lines
670 B
Markdown
# rsync deploy action
|
|
|
|
Example usage:
|
|
|
|
```yaml
|
|
name: 'Build and deploy'
|
|
run-name: 'Build and Deploy'
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
deploy-blog:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout
|
|
- name: Deploy files
|
|
uses: https://git.roy.lv/actions/rsync-deploy-action # Full URL is Gitea Actions specific
|
|
env:
|
|
SSH_KEY: ${{ secrets.SSH_KEY }}
|
|
RSYNC_SOURCE: ./*
|
|
RSYNC_DESTINATION: /path/to/rsync/to/
|
|
RSYNC_USERHOST: user@example.host
|
|
with:
|
|
rsync-arguments: --archive --compress --delete --verbose
|
|
ssh-port: '22'
|
|
```
|