-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
62 lines (58 loc) · 1.44 KB
/
Copy pathdocker-compose.yml
File metadata and controls
62 lines (58 loc) · 1.44 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
name: helldivershangar
services:
helldivershangar-database:
container_name: helldivershangar-database
# image: postgres
build:
context: .
dockerfile: postgres-build/postgres.Dockerfile
restart: always
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_USER: ${DB_USERNAME}
POSTGRES_DB: ${DB_NAME}
POSTGRES_INITDB_ARGS: '--data-checksums'
TZ: ${TZ}
PGTZ: ${TZ}
volumes:
- helldiver-postgres:/var/lib/postgresql/data
command: |-
-c ssl=on
-c ssl_cert_file=/var/lib/postgresql/server.crt
-c ssl_key_file=/var/lib/postgresql/server.key
env_file:
- .env
ports:
- ${DB_PORT}:5432
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}" ]
interval: 10s
timeout: 5s
retries: 5
networks:
- helldivershangar-network
helldivershangar-api:
container_name: helldivershangar-api
image: helldivershangar-api
build:
context: .
dockerfile: Dockerfile
ports:
- "3000:3000"
depends_on:
helldivershangar-database:
condition: service_healthy
env_file:
- .env
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:3000/health" ]
interval: 10s
timeout: 5s
retries: 5
networks:
- helldivershangar-network
volumes:
helldiver-postgres:
networks:
helldivershangar-network:
driver: bridge