All checks were successful
Deploy c4 / deploy (push) Successful in 1m19s
Use a Gitea Actions workflow to deploy on push to main via act_runner on the games VM. Switch from a Docker named volume to a ./data bind mount for easier backup and persistence across deploys.
23 lines
432 B
YAML
23 lines
432 B
YAML
name: Deploy c4
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
|
|
env:
|
|
DEPLOY_DIR: /home/ryan/c4
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Sync to deploy directory
|
|
run: |
|
|
mkdir -p $DEPLOY_DIR
|
|
rsync -a --delete --exclude 'data/' . $DEPLOY_DIR/
|
|
|
|
- name: Rebuild and restart
|
|
run: cd $DEPLOY_DIR && docker compose up -d --build --remove-orphans
|