22 lines
518 B
YAML
22 lines
518 B
YAML
name: decom-dev
|
|
|
|
services:
|
|
postgres:
|
|
image: postgres:16
|
|
ports:
|
|
- "5432:5432"
|
|
environment:
|
|
POSTGRES_USER: ${POSTGRES_USER:-postgres}
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?请设置 POSTGRES_PASSWORD}
|
|
POSTGRES_DB: ${POSTGRES_DB:-decom}
|
|
volumes:
|
|
- decom-pg:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-postgres} -d ${POSTGRES_DB:-decom}"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 20
|
|
|
|
volumes:
|
|
decom-pg:
|