networks: traefik: external: true services: showerloop: image: git.nixc.us/colin/showerloop-cc:production networks: - traefik healthcheck: test: ["CMD", "curl", "-f", "http://localhost/healthcheck.txt"] interval: 30s timeout: 10s retries: 3 start_period: 40s deploy: replicas: 1 placement: constraints: - node.hostname == macmini3 update_config: order: start-first failure_action: rollback delay: 10s restart_policy: condition: on-failure max_attempts: 3 window: 120s labels: traefik.enable: "true" # Unique router and service names traefik.http.routers.showerloop-production-secure.rule: Host(`showerloop.cc`, `www.showerloop.cc`) traefik.http.routers.showerloop-production-secure.entrypoints: "websecure" traefik.http.routers.showerloop-production-secure.tls: "true" traefik.http.routers.showerloop-production-secure.tls.certresolver: "letsencryptresolver" traefik.http.services.showerloop-production-service.loadbalancer.server.port: "80" traefik.docker.network: "traefik" # Health Check traefik.http.services.showerloop-production-service.loadbalancer.healthcheck.path: "/healthcheck.txt" traefik.http.services.showerloop-production-service.loadbalancer.healthcheck.interval: "30s" traefik.http.services.showerloop-production-service.loadbalancer.healthcheck.timeout: "5s" traefik.http.routers.showerloop-production-secure.service: "showerloop-production-service"