-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.prod.yaml
101 lines (99 loc) · 2.6 KB
/
docker-compose.prod.yaml
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
services:
orservice_db:
container_name: orservice_db
env_file: ".env"
restart: unless-stopped
image: postgres:latest
expose:
- "5432"
networks:
orservice_network:
ipv4_address: 10.10.2.2
environment:
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
- POSTGRES_DB=${POSTGRES_DB}
- POSTGRES_INITDB_ARGS="--auth-host=scram-sha-256"
volumes:
- ./postgres-data:/var/lib/postgresql/data
- ./initdb:/docker-entrypoint-initdb.d
logging:
options:
max-size: "10m"
max-file: "3"
healthcheck:
test:
["CMD", "pg_isready", "-U", "${POSTGRES_USER}", "-d", "${POSTGRES_DB}"]
interval: 10s
timeout: 5s
retries: 5
security_opt:
- no-new-privileges:true
orservice_backend:
container_name: orservice_backend
env_file: ".env"
restart: unless-stopped
image: ghcr.io/stevensblueprint/orservice
expose:
- "8080"
networks:
orservice_network:
ipv4_address: 10.10.2.3
environment:
- ORSERVICE_DB_HOST=orservice_db
- ORSERVICE_DB_USER=${POSTGRES_USER}
- ORSERVICE_DB_PASSWORD=${POSTGRES_PASSWORD}
- ORSERVICE_DB_NAME=${POSTGRES_DB}
logging:
options:
max-size: "10m"
max-file: "3"
healthcheck:
test: "curl --fail --silent --max-time 5 localhost:8080/actuator/health | grep UP || exit 1"
interval: 30s
timeout: 10s
retries: 5
start_period: 40s
labels:
- "com.centurylinklabs.watchtower.scope=orservice"
depends_on:
- orservice_db
orservice_ui:
container_name: orservice_ui
restart: unless-stopped
image: ghcr.io/stevensblueprint/orservice_admin
ports:
- "80:8080"
networks:
orservice_network:
ipv4_address: 10.10.2.4
logging:
options:
max-size: "10m"
max-file: "3"
labels:
- "com.centurylinklabs.watchtower.scope=orservice"
healthcheck:
test: "curl --fail --silent --max-time 5 localhost:5173 || exit 1"
environment:
- REACT_APP_USER_POOL_ID = ${USER_POOL_ID}
- REACT_APP_CLIENT_ID = ${CLIENT_ID}
depends_on:
- orservice_backend
wt:
image: containrrr/watchtower
labels:
- "com.centurylinklabs.watchtower.scope=orservice"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
command: --interval 30 --scope orservice
volumes:
postgres-data:
networks:
orservice_network:
driver: bridge
name: orservice_network
ipam:
config:
- subnet: 10.10.2.0/24
gateway: 10.10.2.1