test version runs
Some checks failed
Gitea build & Test. / docker (push) Failing after 3s

This commit is contained in:
WGAVermeer
2026-03-08 14:20:43 +01:00
parent 3fca18e000
commit 9959272051
4 changed files with 11 additions and 7 deletions

View File

@@ -1,15 +1,16 @@
# Django # Django
DJANGO_SETTINGS_MODULE=website.settings DJANGO_SETTINGS_MODULE=website.settings
DJANGO_SECRET_KEY=test_key DJANGO_SECRET_KEY=CWHZCAZBNV57tDkwGHJwTUu3PCSnGG45
DEBUG=TRUE DEBUG=TRUE
ALLOWED_HOSTS=localhost ALLOWED_HOSTS=localhost
# Database (PostgreSQL) # Database (PostgreSQL)
POSTGRES_DB=test_db
POSTGRES_USER=test_user POSTGRES_USER=test_user
POSTGRES_PASSWORD=test_password POSTGRES_PASSWORD=test_password
POSTGRES_HOST=db POSTGRES_HOST=db
POSTGRES_PORT=5432 POSTGRES_PORT=5432
POSTGRES_DBNAME=test_dbname # == POSTGRES_DB
POSTGRES_DB=test_db
# Gunicorn # Gunicorn
GUNICORN_WORKERS=3 GUNICORN_WORKERS=3

View File

@@ -7,4 +7,4 @@ dev:
docker compose -f ./compose.yaml -f ./compose.dev.yaml up --build docker compose -f ./compose.yaml -f ./compose.dev.yaml up --build
test: test:
docker compose -f ./compose.yaml -f ./compose.test.yaml up --build docker compose -f ./compose.yaml -f ./compose.test.yaml up --build --abort-on-container-exit --exit-code-from web

View File

@@ -1,9 +1,12 @@
services: services:
web: web:
env_file: .env.template env_file:
- .env.template
command: python -Wa manage.py test --noinput --parallel command: python -Wa manage.py test --noinput --parallel
restart: "no"
db: db:
env_file: .env.template env_file:
- .env.template

View File

@@ -26,7 +26,7 @@ SECRET_KEY = "django-insecure-c$q7wdq+u@ow74wp!&zzkxdylkueu)(+34e%!e0du&bjwoqz9z
# SECURITY WARNING: don't run with debug turned on in production! # SECURITY WARNING: don't run with debug turned on in production!
DEBUG = bool(os.getenv("DEBUG")) DEBUG = bool(os.getenv("DEBUG"))
ALLOWED_HOSTS = os.getenv("ALLOWED_HOSTS").split(",") ALLOWED_HOSTS = os.getenv("ALLOWED_HOSTS").split(",")
SECURE_PROXY_SSL_HEADER = ("HTTP_X_FORWARDED_PROTO", "https") SECURE_PROXY_SSL_HEADER = ("HTTP_X_FORWARDED_PROTO", "https")
@@ -77,7 +77,7 @@ WSGI_APPLICATION = "website.wsgi.application"
DATABASES = { DATABASES = {
"default": { "default": {
"ENGINE": "django.db.backends.postgresql", "ENGINE": "django.db.backends.postgresql",
"NAME": os.getenv("POSTGRES_NAME"), "DBNAME": os.getenv("POSTGRES_DBNAME"),
"USER": os.getenv("POSTGRES_USER"), "USER": os.getenv("POSTGRES_USER"),
"PASSWORD": os.getenv("POSTGRES_PASSWORD"), "PASSWORD": os.getenv("POSTGRES_PASSWORD"),
"HOST": os.getenv("POSTGRES_HOST"), "HOST": os.getenv("POSTGRES_HOST"),