Skip to content

Commit a04fdae

Browse files
author
Paulo Guilherme Pinheiro Pereira
committed
Change django command to match docker-compose
1 parent d13e6d6 commit a04fdae

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

charts/templates/django-deployment.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,11 @@ spec:
2020
- bash
2121
- -c
2222
- >
23-
python manage.py collectstatic --noinput &&
23+
python manage.py migrate --no-input &&
24+
python manage.py collectstatic --no-input &&
2425
cd {{ .Values.django.workingDir }} &&
2526
watchmedo auto-restart -p '*.py' --recursive --
26-
gunicorn asgi:application -w {{ .Values.django.gunicorn.workers }} -k uvicorn.workers.UvicornWorker -b :{{ .Values.django.port }} --capture-output --log-level {{ .Values.django.gunicorn.logLevel }}
27+
python3 ./gunicorn_run.py
2728
env:
2829
{{- range $key, $value := .Values.env }}
2930
- name: {{ $key }}

charts/values.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,6 @@ django:
2323
replicas: 1
2424
port: 8000
2525
workingDir: /app/src
26-
gunicorn:
27-
workers: 2
28-
logLevel: info
2926

3027
flower:
3128
image:
@@ -130,6 +127,8 @@ db:
130127
port: <database-port>
131128

132129
env:
130+
LOG_LEVEL: "info"
131+
133132
SECRET_KEY: <your-django-secret-key>
134133

135134
DJANGO_SETTINGS_MODULE: settings.develop

0 commit comments

Comments
 (0)