61 lines
1.2 KiB
Nix
61 lines
1.2 KiB
Nix
|
{ config, pkgs, ... }:
|
||
|
|
||
|
let
|
||
|
domain = "home.giugl.io";
|
||
|
in
|
||
|
{
|
||
|
services.home-assistant = {
|
||
|
enable = true;
|
||
|
config = {
|
||
|
http = {
|
||
|
server_host = "127.0.0.1";
|
||
|
server_port = 8123;
|
||
|
use_x_forwarded_for = true;
|
||
|
trusted_proxies = [ "127.0.0.1" ];
|
||
|
};
|
||
|
homeassistant = {
|
||
|
name = "Underwood House";
|
||
|
unit_system = "metric";
|
||
|
};
|
||
|
default_config = { };
|
||
|
};
|
||
|
extraComponents = [
|
||
|
"otbr"
|
||
|
"litterrobot"
|
||
|
"apple_tv"
|
||
|
"homekit"
|
||
|
"homekit_controller"
|
||
|
"spotify"
|
||
|
"hue"
|
||
|
"sonos"
|
||
|
"tplink"
|
||
|
"ollama"
|
||
|
"wyoming"
|
||
|
"whisper"
|
||
|
"piper"
|
||
|
"isal"
|
||
|
"radarr"
|
||
|
"sonarr"
|
||
|
];
|
||
|
extraPackages = python3Packages: with python3Packages; [
|
||
|
pkgs.openai-whisper
|
||
|
openai-whisper
|
||
|
pkgs.piper-tts
|
||
|
pkgs.wyoming-piper
|
||
|
];
|
||
|
};
|
||
|
|
||
|
architect.vhost.${domain} = with config.architect.networks; {
|
||
|
dnsInterfaces = [ "tailscale" "lan" ];
|
||
|
|
||
|
locations."/" = {
|
||
|
port = config.services.home-assistant.config.http.server_port;
|
||
|
allowLan = true;
|
||
|
proxyWebsockets = true;
|
||
|
allow = [
|
||
|
tailscale.net
|
||
|
];
|
||
|
};
|
||
|
};
|
||
|
}
|