services: woodpecker-db: image: docker.io/library/postgres:16-alpine3.20 restart: unless-stopped environment: POSTGRES_PASSWORD: ${POSTGRES_WOODPECKER_PW} POSTGRES_USER: woodpecker POSTGRES_DB: woodpecker POSTGRES_INITDB_ARGS: --encoding=UTF-8 --lc-collate=C --lc-ctype=C network_mode: none volumes: - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro - type: 'volume' source: postgres_run target: /var/run/postgresql/ - postgres_data:/var/lib/postgresql/data healthcheck: test: ["CMD", "pg_isready", "-U", "woodpecker", "-d", "woodpecker"] interval: 10s timeout: 5s retries: 5 volumes: postgres_run: