-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
67 lines (64 loc) · 2.07 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: "3.9"
services:
transit_db:
image: postgres:14
volumes:
- ./docker_data/db:/var/lib/postgresql/data
container_name: transit_db
ports:
- "5440:5432"
environment:
- POSTGRES_DB=${DB_NAME:-TransIT}
- POSTGRES_USER=${DB_USER:-postgres}
- POSTGRES_PASSWORD=${DB_PASSWORD:-postgres}
web:
build: .
command: start
volumes:
- ./:/backend
- ${PWD}/tox.ini:/backend/tox.ini
- ${PWD}/server.py:/backend/server.py
- ./docker_data/media/${MEDIA_ROOT:-files}:/backend/${MEDIA_ROOT:-files}
ports:
- "8000:8000"
environment:
- DB_NAME=${DB_NAME:-TransIT}
- DB_USER=${DB_USER:-postgres}
- DB_PASSWORD=${DB_PASSWORD:-postgres}
- DB_HOST=${DB_HOST:-transit_db} # By default, it's pointing to transit_db container
- DB_PORT=${DB_PORT:-5432}
- PORT=${PORT:-8000}
- DJANGO_SERVER=${DJANGO_SERVER:-django_wsgi} # By default, use development server, actual server should use 'waitress'
- ALLOWED_HOSTS=${ALLOWED_HOSTS:-*} # Warning: '*' should not be used in production
- SUPERUSER_LOGIN=${SUPERUSER_LOGIN}
- SUPERUSER_PASSWORD=${SUPERUSER_PASSWORD}
- SUPERUSER_EMAIL=${SUPERUSER_EMAIL}
- MEDIA_ROOT=${MEDIA_ROOT}
- AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID}
- AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY}
- AWS_BUCKET=${AWS_BUCKET}
- FILE_STORAGE=${FILE_STORAGE}
depends_on:
transit_db:
condition: service_started
superset:
ports:
- "8088:8088"
environment:
- DB_NAME=${SUPERSET_DB_NAME:-superset}
- DB_USER=${DB_USER:-postgres}
- DB_PASSWORD=${DB_PASSWORD:-postgres}
- DB_HOST=${DB_HOST:-db} # By default, it's pointing to db container
- DB_PORT=${DB_PORT:-5432}
build:
context: .
dockerfile: ./superset_setup/Dockerfile
volumes:
- ./superset_setup/superset_config.py:/app/pythonpath/superset_config_docker.py
depends_on:
transit_db:
condition: service_started
networks:
default:
external:
name: transit-network