-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
44 lines (39 loc) · 960 Bytes
/
docker-compose.yml
File metadata and controls
44 lines (39 loc) · 960 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
version: '3.8'
services:
backend:
build: .
restart: unless-stopped
ports:
- "${WEBPROXY_PORT:-8095}:8000"
environment:
POSTGRES_DB: ${POSTGRES_DB:-mockapi}
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-mockapi}
depends_on:
- db
networks:
- app_network
db:
image: docker.io/bitnami/postgresql:17
volumes:
- 'postgresql_master_data:/bitnami/postgresql'
environment:
POSTGRES_DB: ${POSTGRES_DB:-mockapi}
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-mockapi}
expose:
- ${POSTGRESQL_PORT:-5432}
networks:
- app_network
restart: unless-stopped
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 10s
timeout: 5s
retries: 5
networks:
app_network:
driver: bridge
volumes:
postgresql_master_data:
driver: local