feat(deploy): automatic VPS deploy via GHCR on push to main

Build the Docker image in GitHub Actions, publish to
ghcr.io/mauricioabh/arbpulse (latest + sha tags), then SSH into the
Hetzner VPS to docker compose pull + up -d with a health-check gate.
The VPS no longer builds images, keeping CPU/RAM free for the running
apps and making rollbacks a matter of pulling a previous sha tag.

- .github/workflows/vps-deploy.yml: build-push (GHCR) + deploy (SSH) jobs
- deploy/docker-compose.yml: app image now ghcr.io/mauricioabh/arbpulse
- deploy/deploy.sh: pulls from GHCR by default (BUILD=1 for local build),
  default APP_DIR aligned to /root/projects/arbpulse
- docs: deploy/README.md CI/CD section + paths, README deploy section

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Mauricio Barragan
2026-07-19 12:23:49 -06:00
parent 4ffce9a59e
commit f6108d8f8f
5 changed files with 161 additions and 29 deletions
+4 -1
View File
@@ -12,10 +12,13 @@
services:
app:
# Normal flow: the image is built by CI (.github/workflows/vps-deploy.yml)
# and pulled from GHCR. `build:` remains for local/manual builds only
# (docker compose build app).
build:
context: ..
dockerfile: Dockerfile
image: arbpulse:latest
image: ghcr.io/mauricioabh/arbpulse:latest
container_name: arbpulse
restart: unless-stopped
env_file: