-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompose.yaml
More file actions
36 lines (35 loc) · 983 Bytes
/
Copy pathcompose.yaml
File metadata and controls
36 lines (35 loc) · 983 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
services:
mongodb:
image: mongo:8.3.2
restart: unless-stopped
ports:
- "127.0.0.1:27017:27017"
volumes:
- christopherbell_mongo_data:/data/db
healthcheck:
test: ["CMD", "mongosh", "--quiet", "--eval", "quit(db.adminCommand('ping').ok ? 0 : 1)"]
interval: 5s
timeout: 5s
retries: 12
start_period: 10s
stop_grace_period: 30s
postgresql:
image: postgres:18.4
restart: unless-stopped
environment:
POSTGRES_DB: test
POSTGRES_USER: christopherbell_test
POSTGRES_PASSWORD: ${POSTGRES_TEST_PASSWORD:?set POSTGRES_TEST_PASSWORD}
ports:
- "127.0.0.1:5432:5432"
volumes:
- christopherbell_postgresql_data:/var/lib/postgresql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U christopherbell_test -d test"]
interval: 5s
timeout: 5s
retries: 12
start_period: 10s
volumes:
christopherbell_mongo_data: {}
christopherbell_postgresql_data: {}