Files
cv-site/.github/workflows
juanatsap 0f1426a2d0 fix: auto-stash local changes before git pull in deployment
- Check for uncommitted changes (both staged and unstaged)
- Auto-stash with timestamp before pulling
- Prevents "Your local changes would be overwritten" errors
- Commented-out option to reapply stash after pull if needed

Server changes are preserved in git stash for recovery if needed.

Fixes: "error: Your local changes to the following files would be overwritten by merge"
2025-10-31 12:43:35 +00:00
..
2025-10-31 11:06:38 +00:00

GitHub Actions Workflows

deploy.yml - Automated Deployment

Trigger: Push to main branch or manual dispatch

What it does:

  1. SSH into your server
  2. git pull origin main
  3. sudo systemctl restart cv-server
  4. Verify deployment via health check

Required GitHub Secrets:

  • SSH_PRIVATE_KEY - SSH private key for server access
  • SSH_HOST - Server IP or domain
  • SSH_USER - SSH username

Optional GitHub Secrets:

  • SSH_PORT (default: 22)
  • SERVICE_NAME (default: cv-server)
  • REPO_PATH (default: /opt/cv-server)

Manual deployment: Go to Actions → Deploy CV Server → Run workflow

Setup guide: See GITHUB-ACTION-SETUP.md