-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.prod.yml
More file actions
49 lines (45 loc) · 1.02 KB
/
Copy pathdocker-compose.prod.yml
File metadata and controls
49 lines (45 loc) · 1.02 KB
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
version: '3.9'
services:
db:
image: postgres:16-alpine
container_name: rostid_db
restart: unless-stopped
environment:
POSTGRES_USER: ${POSTGRES_USER:-rostid}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DB:-rostid_db}
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ['CMD-SHELL', 'pg_isready -U ${POSTGRES_USER:-rostid}']
interval: 10s
timeout: 5s
retries: 5
server:
build:
context: ./server
dockerfile: Dockerfile.prod
container_name: rostid_server
restart: unless-stopped
depends_on:
db:
condition: service_healthy
env_file: .env
environment:
NODE_ENV: production
ports:
- '4000:4000'
client:
build:
context: ./client
dockerfile: Dockerfile.prod
args:
VITE_API_URL: ${VITE_API_URL}
container_name: rostid_client
restart: unless-stopped
depends_on:
- server
ports:
- '80:80'
volumes:
postgres_data: