services:
  homeassistant:
    image: lscr.io/linuxserver/homeassistant:latest
    container_name: homeassistant
#    network_mode: host
    networks:
      - pangolin-home
      - teslamate_teslamate-internal
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=America/New_York
    volumes:
      - /mnt/docker/home/homeassistant/data:/config
      - /run/dbus:/run/dbus:ro
    cap_add:
      - NET_ADMIN
      - NET_RAW
#    ports:
#      - 8123:8123 #optional
#    devices:
#      - /path/to/device:/path/to/device #optional
    restart: unless-stopped

networks:
  pangolin-home:
    external: true
  teslamate_teslamate-internal:
    external: true