version: "3.8" services: postgres_db: image: postgres:16.1-alpine3.19 container_name: bolt_postgres_db healthcheck: test: ["CMD-SHELL", "pg_isready -U postgres"] interval: 10s timeout: 5s retries: 5 ports: - "${BOLT_DB_CONN_PORT:?err}:5432" environment: - POSTGRES_DB=${BOLT_DB_CONN_DBNAME:?err} - POSTGRES_USER=${BOLT_DB_CONN_USER:?err} - POSTGRES_PASSWORD=${BOLT_DB_CONN_PASSWORD:?err} volumes: - postgres_db_volume:/var/lib/postgresql/data volumes: postgres_db_volume: name: postgres-db-volume