-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.prod.yml
59 lines (58 loc) · 1.32 KB
/
docker-compose.prod.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
version: "3"
networks:
nginx_net:
services:
nginx:
build: ./nginx
image: danone-nginx
ports:
- "8080:80"
- "8043:443"
depends_on:
- app
links:
- app
networks:
- default
- nginx_net
external_links:
- frontend_frontend_1
volumes:
- static:/static
- nginx-log:/var/log/nginx
db:
build: ./db
image: danone-db
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_USER: ${DB_USER}
POSTGRES_DB: ${DB_DATABASE}
ports:
- "5434:5432"
volumes:
- db-data:/var/lib/postgresql/data
app:
build:
context: .
dockerfile: ./app/compose/production/Dockerfile
image: danone-app
ports:
- "3000:${APP_SERVER_PORT:-3000}"
env_file: ./.env
volumes:
- ./app:/app:rw
- node_modules:/app/node_modules
depends_on:
- db
links:
- db
command: ["./wait-for-db.sh", "db:5432", "--", "npm", "run", "start:prod"]
stdin_open: true
tty: true
volumes:
db-config:
db-log:
db-data:
node_modules:
static:
nginx-log: