Merge branch 'master' into master

This commit is contained in:
Alessandro Pezzè 2023-02-06 12:15:35 +01:00 committed by GitHub
commit 5b528d9e12
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 26 additions and 1 deletions

View file

@ -20,7 +20,26 @@ jobs:
- run:
name: Run tests
command: make test
build:
docker:
- image: cimg/python:3.10.9
steps:
- checkout
- run:
name: Pull Submodules
command: |
git submodule init
git submodule update --remote
- run:
name: Install deps
command: make install
- run:
name: Run migrations
command: make setup
- run:
name: Build database
command: make build-db
deploy:
machine:
image: ubuntu-2004:202111-01 # https://circleci.com/docs/2.0/configuration-reference/#available-machine-images with Docker 18.09.3. Newer images don't work
@ -44,9 +63,11 @@ workflows:
test-and-deploy:
jobs:
- test
- build
- deploy:
requires:
- test
- build
filters:
branches:
only:
@ -55,6 +76,7 @@ workflows:
weekly:
jobs:
- test
- build
- deploy:
requires:
- test

View file

@ -18,6 +18,9 @@ dev-install: # Install developer requirements + base requirements
setup: # Set up the project database
python manage.py migrate ${local_config}
build-db: # Build database
echo "from data.v2.build import build_all; build_all()" | python manage.py shell ${local_config}
wipe-sqlite-db: # Delete's the project database
rm -rf db.sqlite3