-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
40 lines (37 loc) · 937 Bytes
/
docker-compose.yml
File metadata and controls
40 lines (37 loc) · 937 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
version: '3.8'
services:
postgres:
image: postgres:15
container_name: postgres_praktikum
environment:
POSTGRES_USER: praktikan
POSTGRES_PASSWORD: p4ssw0rd
POSTGRES_DB: ecommerce
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
- ./init:/docker-entrypoint-initdb.d
- ./data:/data
restart: unless-stopped
healthcheck:
test: ["CMD-SHELL", "pg_isready -U praktikan -d ecommerce"]
interval: 10s
timeout: 5s
retries: 5
pgadmin:
image: dpage/pgadmin4
container_name: pgadmin_praktikum
environment:
PGADMIN_DEFAULT_EMAIL: admin@example.com
PGADMIN_DEFAULT_PASSWORD: p4ssw0rd
ports:
- "5050:80"
volumes:
- pgadmin_data:/var/lib/pgadmin
restart: unless-stopped
depends_on:
- postgres
volumes:
postgres_data:
pgadmin_data: