-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
66 lines (64 loc) · 1.7 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
version: '3.4'
services:
db:
environment:
POSTGRES_HOST_AUTH_METHOD: trust
POSTGRES_DB: traffic_stops
DATABASE_URL: postgres://[email protected]:5432/traffic_stops
image: postgres:12-alpine
ports:
- "9051:5432"
volumes:
- pgdata:/var/lib/postgresql/data
- ./docker-entrypoint.postgres.sql:/docker-entrypoint-initdb.d/init.sql
- ./docker-postgresql.conf:/etc/postgresql/postgresql.conf
command: postgres -c config_file=/etc/postgresql/postgresql.conf
shm_size: 512mb
redis:
image: redis:5-alpine
ports:
- "9052:6379"
volumes:
- redisdata:/data
django:
environment:
DJANGO_SETTINGS_MODULE: traffic_stops.settings.dev
PGHOST: db
PGPORT: 5432
PGUSER: postgres
PGDATABASE: traffic_stops
DATABASE_URL: postgres://postgres@db:5432/traffic_stops
DATABASE_URL_NC: postgres://postgres@db:5432/traffic_stops_nc
CACHE_HOST: redis://redis:6379/1
ENVIRONMENT: dev
DJANGO_SECRET_KEY: dummy
DOMAIN: localhost
SESSION_COOKIE_SECURE: "False"
DJANGO_SECURE_SSL_REDIRECT: "False"
AWS_PROFILE: trafficstops
build:
context: .
dockerfile: Dockerfile
target: dev
command: ["sleep", "infinity"]
links:
- db:db
- redis:redis
ports:
- "9050:8000"
- "9053:3000"
volumes:
- ~/.ssh:/home/appuser/.ssh:delegated
- ~/.aws:/home/appuser/.aws/
- .:/code/
- dev_media:/code/public
- dev_node_modules:/code/frontend/node_modules
- dev_venv:/code/venv
- dev_cache:/home/appuser/.cache/
volumes:
pgdata:
redisdata:
dev_media: {}
dev_node_modules: {}
dev_venv: {}
dev_cache: {}