feat: Added homeassistant remote

This commit is contained in:
uttarayan21
2025-06-15 02:07:28 +05:30
parent 7b87c7071f
commit 935231c118
4 changed files with 38 additions and 2 deletions

View File

@@ -6,6 +6,7 @@
./zerotier.nix
./jellyfin.nix
./autossh.nix
# ./homeassistant.nix
# ./aerospace.nix
];
}

View File

@@ -0,0 +1,28 @@
{
pkgs,
lib,
...
}: {
environment.systemPackages = [pkgs.arion pkgs.docker-client];
virtualisation.docker.enable = lib.mkForce false;
virtualisation.podman.enable = true;
virtualisation.podman.dockerSocket.enable = true;
# users.extraUsers.servius.extraGroups = ["podman"];
# networking.firewall.allowedTCPPorts = [21063 21064];
# networking.firewall.allowedUDPPorts = [5353];
virtualisation.arion = {
backend = "docker";
projects = {
homeassistant.settings.services = {
homeassistant = {
service.image = "ghcr.io/home-assistant/home-assistant:stable";
service.volumes = ["/etc/localtime:/etc/localtime:ro" "/run/dbus:/run/dbus:ro"];
service.privileged = true;
service.network_mode = "host";
service.restart = "unless-stopped";
};
};
};
};
}

View File

@@ -9,6 +9,7 @@
./caddy.nix
./fail2ban.nix
./gitea.nix
./home-assistant.nix
# ./appflowy.nix
# ./jellyfin.nix
@@ -19,7 +20,6 @@
# ./nextcloud.nix
# ./navidrome.nix
# ./ldap.nix
# ./home-assistant.nix
# ./llama.nix
# ./nextcloud.nix
];

View File

@@ -30,8 +30,15 @@
copy_headers Remote-User Remote-Groups Remote-Email Remote-Name
}
reverse_proxy localhost:8123
'';
};
};
networking.firewall.allowedTCPPorts = [5555 5353 1900 51827 48784 38989 18555];
networking.firewall.allowedUDPPorts = [5555];
networking.firewall.allowedTCPPortRanges = [
{
from = 21063;
to = 21070;
}
];
}