diff --git a/nixos/boxes/bolty/default.nix b/nixos/boxes/bolty/default.nix index 4eef2ef3..7c28c483 100644 --- a/nixos/boxes/bolty/default.nix +++ b/nixos/boxes/bolty/default.nix @@ -7,14 +7,8 @@ ./nextcloud.nix ./print-server.nix ./restic-server.nix + ./home-assistant.nix ]; - services.syncthing = { - enable = true; - dataDir = "/data/syncthing"; - openDefaultPorts = true; - package = - inputs.nixpkgs-nixos-unstable.legacyPackages."x86_64-linux".syncthing; - }; boot.binfmt.emulatedSystems = [ "aarch64-linux" ]; networking = { hostName = "bolty"; diff --git a/nixos/boxes/bolty/home-assistant.nix b/nixos/boxes/bolty/home-assistant.nix new file mode 100644 index 00000000..0eeec5fe --- /dev/null +++ b/nixos/boxes/bolty/home-assistant.nix @@ -0,0 +1,14 @@ +{ config, pkgs, inputs, lib, ... }: { + imports = [ ]; + + virtualisation.oci-containers = { + backend = "podman"; + containers.homeassistant = { + volumes = [ "home-assistant:/config" ]; + environment.TZ = "Europe/London"; + image = + "ghcr.io/home-assistant/home-assistant:stable"; # Warning: if the tag does not change, the image will not be updated + extraOptions = [ "--network=host" ]; + }; + }; +}