Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
version: "3"
services:
nginx:
build:
context: .
dockerfile: ./nginx/Dockerfile
ports:
- 80:80
- 443:443
depends_on:
- django
restart: unless-stopped
django:
build: .
ports:
- 8000:8000
environment:
DEBUG: ${DEBUG:-False}
ALLOWED_HOSTS: "django"
DB_NAME: ${DB_NAME:-regi}
DB_PASSWORD: ${DB_PASSWORD:-change_me!}
restart: unless-stopped
depends_on:
- postgres
initial_data:
build: .
command: python manage.py loaddata initial_data.json
environment:
DEBUG: ${DEBUG:-False}
DB_NAME: ${DB_NAME:-regi}
DB_PASSWORD: ${DB_PASSWORD:-change_me!}
depends_on:
- migration
createsuperuser:
build: .
command: "python manage.py shell -c 'from django.contrib.auth.models import User; User.objects.create_superuser(\"admin\", \"${REGI_ADMIN_EMAIL:-admin@admin.de}\", \"${REGI_ADMIN_PASSWORD:-123}\")'"
environment:
DEBUG: ${DEBUG:-False}
DB_NAME: ${DB_NAME:-regi}
DB_PASSWORD: ${DB_PASSWORD:-change_me!}
depends_on:
- postgres
migration:
build: .
command: python manage.py migrate
environment:
DEBUG: ${DEBUG:-False}
DB_NAME: ${DB_NAME:-regi}
DB_PASSWORD: ${DB_PASSWORD:-change_me!}
depends_on:
- postgres
postgres:
image: postgres:10-alpine
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD:-change_me!}
POSTGRES_DB: ${DB_NAME:-regi}
restart: unless-stopped