personal-site/.gitea/workflows/deploy.yml
david f40f5f6643
All checks were successful
Deploy to Pi / deploy (push) Successful in 0s
& changes
2025-04-03 19:34:20 -07:00

28 lines
509 B
YAML

name: Deploy to Pi
on:
push:
branches:
- actions
jobs:
deploy:
runs-on: self-hosted
steps:
- name: Checkout code
run: |
cd ~/personal-site
git checkout actions
git pull origin actions
- name: Stop existing server, if running
run: |
pkill -f 'python3 -m http.server' || true
- name: Start server
run: |
cd ~/personal-site
chmod +x ./start.sh
./start.sh > server.log 2>&1