Skip to content

Upgrade to Django 5.0 #59

Upgrade to Django 5.0

Upgrade to Django 5.0 #59

Workflow file for this run

name: Python CI
on:
push:
branches: [ main ]
pull_request:
branches: "*"
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: ["3.12"]
env:
DATABASE_URL: sqlite://
SECRET_KEY: something_very_secret
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: pip install pip-tools && pip-sync requirements.txt
- name: Collect static
run: python manage.py collectstatic --no-input
- name: Run Tests
run: pytest
env:
FLAKYTEST_SECRET_TOKEN: ${{ secrets.FLAKYTEST_SECRET_TOKEN }}
deploy:
runs-on: ubuntu-22.04
needs: test
if: github.ref == 'refs/heads/main'
steps:
- name: Deploy
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USERNAME }}
key: ${{ secrets.SSH_KEY }}
port: ${{ secrets.SSH_PORT }}
script: |
bash projects/surfcamsapi/update.sh