version: '3.8' services: web: image: nginx:alpine ports: - "8082:80" healthcheck: # This will always fail because port 9999 doesn't exist test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:9999/"] interval: 10s timeout: 5s retries: 3 start_period: 5s