Sc#12migrate-backend-to-django-drf - soft commits to one #29
Workflow file for this run
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: Backend tests | |
env: | |
DOCKER_BUILDKIT: 1 | |
COMPOSE_DOCKER_CLI_BUILD: 1 | |
on: | |
pull_request: | |
branches: | |
- dev | |
- main | |
- master | |
push: | |
paths: | |
- '.github/**' | |
- 'backend/**' | |
jobs: | |
pytest: | |
runs-on: ubuntu-latest | |
env: | |
CPLUS_INCLUDE_PATH: /usr/include/gdal | |
C_INCLUDE_PATH: /usr/include/gdal | |
DJANGO_SETTINGS_MODULE: core.settings.development | |
ENVIRONMENT: development | |
SECRET_KEY: app_secret_key | |
DEBUG: 1 | |
ALLOWED_HOSTS: "localhost,127.0.0.1" | |
POSTGRES_HOST: localhost | |
POSTGRES_USER: postgres | |
POSTGRES_PASSWORD: triplane | |
POSTGRES_DB: postgres-triplane | |
POSTGRES_PORT: 5432 | |
STORAGE_ENDPOINT_URL: http://localhost:9000 | |
STORAGE_ACCESS_KEY: superuser | |
STORAGE_SECRET_KEY: superuser | |
STORAGE_SECURE: "False" | |
STORAGE_BUCKET_NAME: files | |
steps: | |
- name: Checkout Code Repository | |
uses: actions/checkout@v4 | |
- name: Build Tests | |
run: docker compose --profile test build | |
- name: Run Tests | |
run: docker compose --profile test run --rm | |
- name: Stop Docker containers | |
run: docker compose down |