diff --git a/backend/Dockerfile b/backend/Dockerfile index e9af939..850475b 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -1,5 +1,9 @@ FROM python:3.8-slim-bullseye +ENV DJANGO_SUPERUSER_USERNAME=admin +ENV DJANGO_SUPERUSER_EMAIL=admin@admin.com +ENV DJANGO_SUPERUSER_PASSWORD=admin + WORKDIR /app COPY ./requirements.txt /app/requirements.txt diff --git a/docker-compose.yaml b/docker-compose.yaml index c68f1c0..440cc6a 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -19,6 +19,7 @@ services: - "8000:8000" command: bash -c "./manage.py makemigrations; ./manage.py migrate; + ./manage.py createsuperuser --noinput; ./manage.py runserver 0.0.0.0:8000" react-frontend: