feat: port home assistant (part 1)
This commit is contained in:
parent
0d8776d8e7
commit
3ba686f159
@ -126,60 +126,6 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
pepe.services.homeassistant = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.unstablePkgs.home-assistant;
|
|
||||||
domain = "home.giugl.io";
|
|
||||||
extraComponents = [
|
|
||||||
"otbr"
|
|
||||||
"litterrobot"
|
|
||||||
"apple_tv"
|
|
||||||
"homekit"
|
|
||||||
"homekit_controller"
|
|
||||||
"spotify"
|
|
||||||
"hue"
|
|
||||||
"sonos"
|
|
||||||
"tplink"
|
|
||||||
"ollama"
|
|
||||||
"wyoming"
|
|
||||||
"whisper"
|
|
||||||
"piper"
|
|
||||||
"isal"
|
|
||||||
"radarr"
|
|
||||||
"sonarr"
|
|
||||||
"mqtt"
|
|
||||||
"mqtt_eventstream"
|
|
||||||
"mqtt_json"
|
|
||||||
"mqtt_room"
|
|
||||||
"mqtt_statestream"
|
|
||||||
"github"
|
|
||||||
"webostv"
|
|
||||||
"reolink"
|
|
||||||
"onvif"
|
|
||||||
"xiaomi_miio"
|
|
||||||
"ring"
|
|
||||||
];
|
|
||||||
extraPackages = python3Packages: with pkgs.unstablePkgs.python3Packages; [
|
|
||||||
pyporscheconnectapi
|
|
||||||
];
|
|
||||||
config = {
|
|
||||||
http = {
|
|
||||||
server_host = "127.0.0.1";
|
|
||||||
server_port = 8123;
|
|
||||||
use_x_forwarded_for = true;
|
|
||||||
trusted_proxies = [ "127.0.0.1" ];
|
|
||||||
};
|
|
||||||
homeassistant = {
|
|
||||||
name = "Brigettine Square";
|
|
||||||
latitude = 52.1958;
|
|
||||||
longitude = 0.180746;
|
|
||||||
unit_system = "metric";
|
|
||||||
};
|
|
||||||
default_config = { };
|
|
||||||
automation = "!include automations.yaml";
|
|
||||||
frontend.themes = "!include_dir_merge_named themes";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
gitea = {
|
gitea = {
|
||||||
@ -222,16 +168,73 @@ in
|
|||||||
domain = "media.giugl.io";
|
domain = "media.giugl.io";
|
||||||
package = pkgs.unstablePkgs.jellyfin;
|
package = pkgs.unstablePkgs.jellyfin;
|
||||||
};
|
};
|
||||||
|
|
||||||
jellyseer = {
|
jellyseer = {
|
||||||
enable = true;
|
enable = true;
|
||||||
domain = "aumm-aumm.giugl.io";
|
domain = "aumm-aumm.giugl.io";
|
||||||
};
|
};
|
||||||
|
|
||||||
prowlarr = {
|
prowlarr = {
|
||||||
enable = true;
|
enable = true;
|
||||||
domain = "htpro.giugl.io";
|
domain = "htpro.giugl.io";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
homeassistant = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.unstablePkgs.home-assistant;
|
||||||
|
domain = "home.giugl.io";
|
||||||
|
extraComponents = [
|
||||||
|
"otbr"
|
||||||
|
"litterrobot"
|
||||||
|
"apple_tv"
|
||||||
|
"homekit"
|
||||||
|
"homekit_controller"
|
||||||
|
"spotify"
|
||||||
|
"hue"
|
||||||
|
"sonos"
|
||||||
|
"tplink"
|
||||||
|
"ollama"
|
||||||
|
"wyoming"
|
||||||
|
"whisper"
|
||||||
|
"piper"
|
||||||
|
"isal"
|
||||||
|
"radarr"
|
||||||
|
"sonarr"
|
||||||
|
"mqtt"
|
||||||
|
"mqtt_eventstream"
|
||||||
|
"mqtt_json"
|
||||||
|
"mqtt_room"
|
||||||
|
"mqtt_statestream"
|
||||||
|
"github"
|
||||||
|
"webostv"
|
||||||
|
"reolink"
|
||||||
|
"onvif"
|
||||||
|
"xiaomi_miio"
|
||||||
|
"ring"
|
||||||
|
];
|
||||||
|
|
||||||
|
extraPackages = python3Packages: with pkgs.unstablePkgs.python3Packages; [
|
||||||
|
pyporscheconnectapi
|
||||||
|
];
|
||||||
|
|
||||||
|
config = {
|
||||||
|
http = {
|
||||||
|
server_host = "127.0.0.1";
|
||||||
|
server_port = 8123;
|
||||||
|
use_x_forwarded_for = true;
|
||||||
|
trusted_proxies = [ "127.0.0.1" ];
|
||||||
|
};
|
||||||
|
homeassistant = {
|
||||||
|
name = "Brigettine Square";
|
||||||
|
latitude = 52.1958;
|
||||||
|
longitude = 0.180746;
|
||||||
|
unit_system = "metric";
|
||||||
|
};
|
||||||
|
default_config = { };
|
||||||
|
automation = "!include automations.yaml";
|
||||||
|
frontend.themes = "!include_dir_merge_named themes";
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -1,115 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
domain = "home.giugl.io";
|
|
||||||
piperPort = 10200;
|
|
||||||
whisperPort = 10300;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
services.go2rtc = {
|
|
||||||
enable = true;
|
|
||||||
settings.api.listen = "127.0.0.1:1984";
|
|
||||||
};
|
|
||||||
|
|
||||||
# services.wyoming = {
|
|
||||||
# faster-whisper = {
|
|
||||||
# servers."home" = {
|
|
||||||
# enable = true;
|
|
||||||
# uri = "tcp://127.0.0.1:${toString whisperPort}";
|
|
||||||
# model = "large-v3";
|
|
||||||
# device = "cuda";
|
|
||||||
# language = "en";
|
|
||||||
# };
|
|
||||||
# };
|
|
||||||
# piper = {
|
|
||||||
# servers."home" = {
|
|
||||||
# enable = true;
|
|
||||||
# uri = "tcp://127.0.0.1:${toString piperPort}";
|
|
||||||
# voice = "en-us-ryan-medium";
|
|
||||||
# lengthScale = 0.63;
|
|
||||||
# };
|
|
||||||
# };
|
|
||||||
# };
|
|
||||||
|
|
||||||
services.home-assistant = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.unstablePkgs.home-assistant;
|
|
||||||
config = {
|
|
||||||
http = {
|
|
||||||
server_host = "127.0.0.1";
|
|
||||||
server_port = 8123;
|
|
||||||
use_x_forwarded_for = true;
|
|
||||||
trusted_proxies = [ "127.0.0.1" ];
|
|
||||||
};
|
|
||||||
homeassistant = {
|
|
||||||
name = "Brigettine Square";
|
|
||||||
latitude = 52.1958;
|
|
||||||
longitude = 0.180746;
|
|
||||||
unit_system = "metric";
|
|
||||||
};
|
|
||||||
default_config = { };
|
|
||||||
automation = "!include automations.yaml";
|
|
||||||
frontend.themes = "!include_dir_merge_named themes";
|
|
||||||
};
|
|
||||||
|
|
||||||
extraComponents = [
|
|
||||||
"otbr"
|
|
||||||
"litterrobot"
|
|
||||||
"apple_tv"
|
|
||||||
"homekit"
|
|
||||||
"homekit_controller"
|
|
||||||
"spotify"
|
|
||||||
"hue"
|
|
||||||
"sonos"
|
|
||||||
"tplink"
|
|
||||||
"ollama"
|
|
||||||
"wyoming"
|
|
||||||
"whisper"
|
|
||||||
"piper"
|
|
||||||
"isal"
|
|
||||||
"radarr"
|
|
||||||
"sonarr"
|
|
||||||
"mqtt"
|
|
||||||
"mqtt_eventstream"
|
|
||||||
"mqtt_json"
|
|
||||||
"mqtt_room"
|
|
||||||
"mqtt_statestream"
|
|
||||||
"github"
|
|
||||||
"webostv"
|
|
||||||
"reolink"
|
|
||||||
"onvif"
|
|
||||||
"xiaomi_miio"
|
|
||||||
"ring"
|
|
||||||
];
|
|
||||||
|
|
||||||
extraPackages = python3Packages: with pkgs.unstablePkgs.python3Packages; [
|
|
||||||
pyporscheconnectapi
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
services.mosquitto = {
|
|
||||||
enable = true;
|
|
||||||
listeners = [
|
|
||||||
{
|
|
||||||
address = "127.0.0.1";
|
|
||||||
acl = [ "pattern readwrite #" ];
|
|
||||||
omitPasswordAuth = true;
|
|
||||||
settings.allow_anonymous = true;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
architect.vhost.${domain} = with config.architect.networks; {
|
|
||||||
dnsInterfaces = [ "tailscale" "lan" ];
|
|
||||||
|
|
||||||
locations."/" = {
|
|
||||||
port = config.services.home-assistant.config.http.server_port;
|
|
||||||
allowWAN = true;
|
|
||||||
allowLan = true;
|
|
||||||
proxyWebsockets = true;
|
|
||||||
allow = [
|
|
||||||
tailscale.net
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
Loading…
x
Reference in New Issue
Block a user