-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
38 lines (36 loc) · 1019 Bytes
/
Copy pathdocker-compose.yml
File metadata and controls
38 lines (36 loc) · 1019 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
version: '3.8'
services:
postgres:
image: postgres:15-alpine
environment:
POSTGRES_USER: ${DB_USER:-eligibility}
POSTGRES_PASSWORD: ${DB_PASSWORD:-dev_password}
POSTGRES_DB: ${DB_NAME:-eligibility_db}
POSTGRES_HOST_AUTH_METHOD: md5
ports:
- "${DB_PORT:-5435}:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${DB_USER:-eligibility}"]
interval: 5s
timeout: 5s
retries: 5
postgres_test:
image: postgres:15-alpine
environment:
POSTGRES_USER: ${TEST_DB_USER:-eligibility}
POSTGRES_PASSWORD: ${TEST_DB_PASSWORD:-test_password}
POSTGRES_DB: ${TEST_DB_NAME:-eligibility_test_db}
POSTGRES_HOST_AUTH_METHOD: md5
ports:
- "${TEST_DB_PORT:-5436}:5432"
tmpfs:
- /var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U eligibility"]
interval: 5s
timeout: 5s
retries: 5
volumes:
postgres_data: