services: postgres: image: postgres:17-alpine environment: POSTGRES_DB: expenses POSTGRES_USER: expenses POSTGRES_PASSWORD: expenses ports: - 5432:5432 healthcheck: test: ["CMD-SHELL", "pg_isready -U expenses -d expenses"] interval: 5s timeout: 5s retries: 5 volumes: - postgres-data:/var/lib/postgresql/data volumes: postgres-data: