--- services: postgres: image: postgres:17-alpine environment: - POSTGRES_USER=ipam - POSTGRES_PASSWORD=ipam - POSTGRES_DB=ipam restart: always volumes: - db_data:/var/lib/postgresql/data healthcheck: test: ["CMD-SHELL", "pg_isready" , "--dbname=ipam", "--username=ipam"] interval: 10s timeout: 5s retries: 5 expose: - 5432 ipam: image: go-ipam build: context: . environment: - GOIPAM_GRPC_SERVER_ENDPOINT=0.0.0.0:9090 - GOIPAM_PG_HOST=postgres - GOIPAM_PG_PORT=5432 - GOIPAM_PG_USER=ipam - GOIPAM_PG_PASSWORD=ipam - GOIPAM_PG_DBNAME=ipam - GOIPAM_LOG_LEVEL=debug restart: always command: postgres ports: - 9090:9090 - 2112:2112 healthcheck: test: ["CMD", "/bin/grpc_health_probe", "-addr","localhost:9090"] interval: 10s timeout: 2s retries: 3 start_period: 10s depends_on: - postgres volumes: db_data: