1
0
Fork 0

skip part of home assistant onboarding because we use LDAP

This commit is contained in:
ibizaman 2023-11-17 22:52:51 -08:00 committed by Pierre Penninckx
parent 8728df8732
commit 052a805679

View file

@ -94,10 +94,12 @@ in
logger.default = "info";
homeassistant = {
external_url = "https://${cfg.subdomain}.${cfg.domain}";
name = "!secret name";
country = "!secret country";
latitude = "!secret latitude_home";
longitude = "!secret longitude_home";
time_zone = "America/Los_Angeles";
time_zone = "!secret time_zone";
unit_system = "metric";
auth_providers = [
# Ensure you have the homeassistant provider enabled if you want to continue using your existing accounts
# { type = "homeassistant"; }
@ -157,6 +159,27 @@ in
};
};
systemd.services.home-assistant.preStart =
let
onboarding = pkgs.writeText "onboarding" ''
{
"version": 4,
"minor_version": 1,
"key": "onboarding",
"data": {
"done": [
"user",
"core_config"
]
}
}
'';
file = "${config.services.home-assistant.configDir}/.storage/onboarding";
in
''
-f ${file} || cp ${onboarding} ${file}
'';
sops.secrets."home-assistant" = {
inherit (cfg) sopsFile;
mode = "0440";