Enable Sentry error monitoring #183
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: Start Project | |
on: | |
pull_request: | |
push: | |
branches: [main] | |
# Restrict jobs in this workflow to have no permissions by default; permissions | |
# should be granted per job as needed using a dedicated `permissions` block | |
permissions: {} | |
jobs: | |
creates-valid-project: | |
permissions: | |
contents: read | |
runs-on: ubuntu-latest | |
services: | |
postgres: | |
image: postgres:16 | |
env: | |
POSTGRES_USER: dev | |
POSTGRES_PASSWORD: dev_password | |
options: >- | |
--health-cmd pg_isready | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
ports: | |
# Allows us to use the same env config used locally by mapping to port to | |
# the test runner container. | |
- 5432:5432 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: "3.12" | |
- name: Install Dependencies | |
run: | | |
sudo apt-get update | |
# Project System Dependencies | |
sudo apt-get install -y \ | |
build-essential \ | |
libffi-dev \ | |
libpq-dev | |
# Base Python tooling | |
pip install invoke poetry django | |
- name: Create test project | |
run: | | |
django-admin startproject \ | |
--template template/ \ | |
--extension py,Dockerfile,env,toml,yml \ | |
test_project | |
- name: Install test project | |
run: | | |
cd test_project | |
poetry run invoke install | |
- name: Check test project is valid | |
run: | | |
cd test_project | |
cp example.env .env | |
poetry run invoke check |