conference-site/.gitea/workflows/build-deploy.yml

25 lines
764 B
YAML
Raw Normal View History

2024-03-02 00:26:27 +00:00
---
name: Build and Deploy
on: [push]
jobs:
Build:
runs-on: site-builder
steps:
2024-03-02 17:17:58 +00:00
- run: git clone ${{ gitea.repository }}
- run: /app/venv/bin/pip install -r conference-site/requirements.txt
- run: /app/venv/bin/pelican conference-site/content -o output -s publishconf.py
2024-03-02 00:26:27 +00:00
Deploy:
runs-on: debian-bookworm
steps:
- uses: easingthemes/ssh-deploy@main
env:
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
2024-03-02 17:17:58 +00:00
SOURCE: output/
2024-03-02 00:26:27 +00:00
REMOTE_HOST: ${{ secrets.REMOTE_HOST }}
REMOTE_USER: ${{ secrets.REMOTE_USER }}
REMOTE_PORT: ${{ secrets.REMOTE_PORT }}
TARGET: /var/www/conference
SCRIPT_AFTER: |
sudo chown -R root:www-data /var/www/conference