-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathdocker-compose.prod.yml
More file actions
78 lines (73 loc) · 1.62 KB
/
docker-compose.prod.yml
File metadata and controls
78 lines (73 loc) · 1.62 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
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
services:
postgres:
image: postgres:15-alpine
container_name: rukhalt-db-prod
restart: always
environment:
POSTGRES_DB: ${DB_NAME}
POSTGRES_USER: ${DB_USER}
POSTGRES_PASSWORD: ${DB_PASSWORD}
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${DB_USER} -d ${DB_NAME}"]
interval: 10s
timeout: 5s
retries: 5
networks:
- rukhalt-network
redis:
image: redis:7-alpine
container_name: rukhalt-redis-prod
restart: always
volumes:
- redis_data:/data
networks:
- rukhalt-network
server:
build:
context: ./server
dockerfile: Dockerfile
image: rukhalt-server:latest
container_name: rukhalt-server-prod
restart: always
environment:
DB_HOST: postgres
DB_PORT: 5432
DB_NAME: ${DB_NAME}
DB_USER: ${DB_USER}
DB_PASSWORD: ${DB_PASSWORD}
DB_SSL_MODE: disable
JWT_SECRET: ${JWT_SECRET}
ENCRYPTION_KEY: ${ENCRYPTION_KEY}
PORT: 8080
GIN_MODE: release
ports:
- "8080:8080"
depends_on:
postgres:
condition: service_healthy
volumes:
- ./backups:/app/backups
- ./logs:/app/logs
networks:
- rukhalt-network
client:
build:
context: ./client
dockerfile: Dockerfile
image: rukhalt-client:latest
container_name: rukhalt-client-prod
restart: always
ports:
- "3000:3000"
depends_on:
- server
networks:
- rukhalt-network
volumes:
postgres_data:
redis_data:
networks:
rukhalt-network:
driver: bridge