Update and deploy #536
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update and deploy | |
on: | |
schedule: | |
# run at 3.15am every day | |
- cron: 15 3 * * * | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python 3.9 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.9 | |
- name: Install dependencies | |
run: pip install -r requirements.txt | |
- name: Compile site | |
run: ./bw-dev site:compile | |
- name: Deploy to server | |
id: deploy | |
uses: Pendect/[email protected] | |
env: | |
DEPLOY_KEY: ${{secrets.DEPLOY_KEY}} | |
with: | |
flags: '-avzr --delete' | |
options: '' | |
ssh_options: '' | |
src: 'site/' | |
dest: '[email protected]:/var/www/join-bookwyrm/html' |