version: '3.7' services: hass: image: ghcr.io/home-assistant/home-assistant:stable volumes: - /mnt/nfs/hass:/config - /etc/localtime:/etc/localtime:ro networks: - storage - smarthome - external deploy: mode: replicated replicas: 1 restart_policy: condition: any max_attempts: 3 labels: - "traefik.enable=true" - "traefik.http.routers.hass.rule=Host(`hass.bxl.bhasher.com`)" - "traefik.http.routers.hass.entrypoints=internalsecure" - "traefik.http.services.hass.loadbalancer.server.port=8123" - "traefik.http.routers.hass.tls=true" - "traefik.http.routers.hass.tls.certresolver=http" placement: constraints: - node.labels.POWER == true depends_on: - system_traefik - system_nfs - storage_postgres mosquitto: image: eclipse-mosquitto:latest volumes: - /mnt/nfs/mosquitto/config:/mosquitto/config - /mnt/nfs/mosquitto/data:/mosquitto/data ports: - 1883:1883 - 9001:9001 networks: - smarthome - external deploy: mode: replicated replicas: 1 restart_policy: condition: any max_attempts: 3 placement: constraints: - node.labels.POWER == true depends_on: - system_nfs networks: smarthome: storage: external: true external: external: true