-
Notifications
You must be signed in to change notification settings - Fork 255
/
docker-compose.yml
67 lines (65 loc) · 2.14 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
version: '2'
services:
nginx:
restart: unless-stopped
build:
context: .
dockerfile: ./docker/nginx/Dockerfile
ports:
- 80:80
volumes:
- static_volume:/app/mercury/django_static
- media_volume:/app/mercury/media
- ./docker/nginx:/etc/nginx/conf.d
depends_on:
- mercury
command: "/bin/sh -c 'nginx -g \"daemon off;\"'"
mercury:
restart: unless-stopped
build:
context: .
dockerfile: ./docker/mercury/Dockerfile
entrypoint: /app/docker/mercury/entrypoint.sh
volumes:
- ${NOTEBOOKS_PATH}:/app/notebooks
- static_volume:/app/mercury/django_static
- media_volume:/app/mercury/media
expose:
- 9000
environment:
DEBUG: ${DEBUG}
SERVE_STATIC: ${SERVE_STATIC}
DJANGO_SUPERUSER_USERNAME: ${DJANGO_SUPERUSER_USERNAME}
DJANGO_SUPERUSER_PASSWORD: ${DJANGO_SUPERUSER_PASSWORD}
DJANGO_SUPERUSER_EMAIL: ${DJANGO_SUPERUSER_EMAIL}
SECRET_KEY: ${SECRET_KEY}
ALLOWED_HOSTS: ${ALLOWED_HOSTS}
WELCOME: ${WELCOME}
EMAIL_HOST: ${EMAIL_HOST}
EMAIL_HOST_USER: ${EMAIL_HOST_USER}
EMAIL_HOST_PASSWORD: ${EMAIL_HOST_PASSWORD}
EMAIL_PORT: ${EMAIL_PORT}
DEFAULT_FROM_EMAIL: ${DEFAULT_FROM_EMAIL}
DJANGO_DB: postgresql
POSTGRES_HOST: db
POSTGRES_NAME: postgres
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_PORT: 5432
MERCURY_VERBOSE: ${MERCURY_VERBOSE}
DJANGO_LOG_LEVEL: ${DJANGO_LOG_LEVEL}
depends_on:
- db
db:
image: postgres:13.0-alpine
restart: unless-stopped
volumes:
- postgres_data:/var/lib/postgresql/data/
environment:
POSTGRES_DB: postgres
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
volumes:
static_volume: {}
media_volume: {}
postgres_data: {}