2
0
mirror of https://github.com/acepanel/templates.git synced 2026-02-04 06:17:13 +08:00
Files
templates/postgresql/docker-compose.yml
2026-01-16 06:31:57 +08:00

24 lines
582 B
YAML

services:
postgres:
image: postgres:18.1-alpine
restart: always
environment:
- POSTGRES_USER=${POSTGRESQL_DB_ROOT_USER}
- POSTGRES_PASSWORD=${POSTGRESQL_DB_ROOT_PASSWORD}
ports:
- ${POSTGRESQL_PORT}:5432
volumes:
- ./data:/var/lib/postgresql
healthcheck:
test: ["CMD", "pg_isready", "-h", "127.0.0.1", "-p", "5432", "-q", "-U", "${POSTGRESQL_DB_ROOT_USER}"]
start_period: 20s
interval: 30s
retries: 5
timeout: 5s
networks:
- acepanel-network
networks:
acepanel-network:
external: true