services: homeassistant: image: ghcr.io/home-assistant/home-assistant:stable container_name: homeassistant network_mode: host environment: - PUID=${USER_ID} - PGID=${GROUP_ID} - TZ=${TIMEZONE} volumes: - ${CONFIG_ROOT:-.}/homeassistant:/config - /etc/localtime:/etc/localtime:ro - /run/dbus:/run/dbus:ro restart: always healthcheck: test: [ "CMD", "curl", "--fail", "http://127.0.0.1:8123" ] interval: 30s retries: 10 privileged: true labels: - traefik.enable=true - traefik.http.routers.homeassistant.rule=(Host(`${HOMEASSISTANT_HOSTNAME}`)) - traefik.http.routers.homeassistant.tls=true - traefik.http.routers.homeassistant.tls.certresolver=myresolver - traefik.http.services.homeassistant.loadbalancer.server.port=8123 - homepage.group=Apps - homepage.name=Home Assistant - homepage.icon=home-assistant.png - homepage.href=https://${HOMEASSISTANT_HOSTNAME} - homepage.description=Open source home automation that puts local control and privacy first - homepage.weight=3 - homepage.widget.type=homeassistant - homepage.widget.url=https://${HOMEASSISTANT_HOSTNAME} - homepage.widget.key=${HOMEASSISTANT_ACCESS_TOKEN} profiles: - homeassistant homeassistant-backup: image: adrienpoupa/rclone-backup:latest container_name: homeassistant-backup restart: always env_file: - ${CONFIG_ROOT:-.}/homeassistant/backup.env environment: - BACKUP_FOLDER_NAME=backups - BACKUP_FOLDER_PATH=/backups volumes: - ${CONFIG_ROOT:-.}/homeassistant/backups:/backups - ${CONFIG_ROOT:-.}/homeassistant/backup:/config profiles: - homeassistant