blob: 61041790894d51ede3181949fd2538dea32f1db5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
services:
postgres:
image: postgres:16
container_name: rpserver_postgres
environment:
POSTGRES_DB: rpserver
POSTGRES_USER: ${DB_USER:-postgres}
POSTGRES_PASSWORD: ${DB_PASSWORD}
volumes:
- postgres_data:/var/lib/postgresql/data
ports:
- "5433:5432"
restart: unless-stopped
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${DB_USER:-postgres}"]
interval: 10s
timeout: 5s
retries: 5
volumes:
postgres_data:
name: rpserver_postgres_data # Named volume for Postgres data persistence
|