From ab3de7a0422d548d14d8b8554ddf43918e7c16ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kier=C3=A1n=20Meinhardt?= Date: Thu, 10 Mar 2022 22:59:43 +0100 Subject: [PATCH] feat(home-assistant): run in podman on zaatar --- systems/zaatar/configuration.nix | 1 + systems/zaatar/home-assistant.nix | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 systems/zaatar/home-assistant.nix diff --git a/systems/zaatar/configuration.nix b/systems/zaatar/configuration.nix index 16a4b9e..8b7d7a1 100644 --- a/systems/zaatar/configuration.nix +++ b/systems/zaatar/configuration.nix @@ -13,6 +13,7 @@ in { ./kiosk.nix ./moodle-dl-meinhark.nix ./pulseaudio.nix + ./home-assistant.nix ./tuna.nix ./grocy.nix ./spotifyd.nix diff --git a/systems/zaatar/home-assistant.nix b/systems/zaatar/home-assistant.nix new file mode 100644 index 0000000..e8e0a51 --- /dev/null +++ b/systems/zaatar/home-assistant.nix @@ -0,0 +1,16 @@ +{ + networking.firewall.allowedTCPPorts = [8123]; + + virtualisation.oci-containers = { + backend = "podman"; + containers.homeassistant = { + volumes = ["home-assistant:/config"]; + environment.TZ = "Europe/Berlin"; + image = "ghcr.io/home-assistant/home-assistant:stable"; + extraOptions = [ + "--network=host" + # "--device=/dev/ttyUSB0:/dev/ttyACM0" # Example, change this to match your own hardware + ]; + }; + }; +}