forked from thedevs-network/kutt
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.postgres.yml
More file actions
44 lines (44 loc) · 860 Bytes
/
docker-compose.postgres.yml
File metadata and controls
44 lines (44 loc) · 860 Bytes
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
services:
server:
build:
context: .
volumes:
- custom:/kutt/custom
environment:
DB_CLIENT: pg
DB_HOST: postgres
DB_PORT: 5432
REDIS_ENABLED: true
REDIS_HOST: redis
REDIS_PORT: 6379
ports:
- 3000:3000
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_started
postgres:
image: postgres
restart: always
user: ${DB_USER}
volumes:
- db_data_pg:/var/lib/postgresql/data
environment:
POSTGRES_DB: ${DB_NAME}
POSTGRES_PASSWORD: ${DB_PASSWORD}
expose:
- 5432
healthcheck:
test: [ "CMD", "pg_isready" ]
interval: 10s
timeout: 5s
retries: 5
redis:
image: redis:alpine
restart: always
expose:
- 6379
volumes:
db_data_pg:
custom: