Files
ZNJJ-api-server/compose.agent-db.yml
T

19 lines
579 B
YAML
Raw Normal View History

services:
postgres:
image: postgres:17-alpine
ports:
- "127.0.0.1:${AGENT_POSTGRES_PORT:-5432}:5432"
environment:
POSTGRES_USER: ${AGENT_POSTGRES_USER:-agent}
POSTGRES_DB: ${AGENT_POSTGRES_DB:-agent}
POSTGRES_PASSWORD: ${AGENT_POSTGRES_PASSWORD:?Set AGENT_POSTGRES_PASSWORD in .env}
volumes:
- agent_postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U \"$${POSTGRES_USER}\" -d \"$${POSTGRES_DB}\""]
interval: 5s
timeout: 3s
retries: 20
volumes:
agent_postgres_data: