services: app: build: context: . dockerfile: Dockerfile container_name: vpn-panel restart: unless-stopped ports: - "${APP_PORT:-8080}:8080" env_file: - .env environment: DATABASE_URL: postgres://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_DB}?sslmode=disable POSTGRES_HOST: postgres depends_on: postgres: condition: service_healthy networks: - vpn-net postgres: image: postgres:17-alpine container_name: vpn-panel-db restart: unless-stopped environment: POSTGRES_DB: ${POSTGRES_DB} POSTGRES_USER: ${POSTGRES_USER} POSTGRES_PASSWORD: ${POSTGRES_PASSWORD} volumes: - postgres_data:/var/lib/postgresql/data healthcheck: test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"] interval: 5s timeout: 5s retries: 10 networks: - vpn-net volumes: postgres_data: networks: vpn-net: name: vpn-panel-net driver: bridge