This repository has been archived on 2024-03-26. You can view files and clone it, but cannot push or open issues or pull requests.
nixos/modules/home-assistant.nix

54 lines
1.2 KiB
Nix
Raw Permalink Normal View History

2023-12-25 23:29:51 +05:30
{ config, lib, pkgs, ... }:
{
services.home-assistant = {
2024-01-01 10:09:36 +05:30
enable = false;
2023-12-25 23:29:51 +05:30
openFirewall = true;
configWritable = true; # remove after setup
configDir = "/var/lib/hass";
config = {
lovelace.mode = "yaml";
server_port = 8123;
server_host = [
"0.0.0.0"
"::"
];
homeassistant = {
name = "Norumbega";
unit_system = "metric";
temperature_unit = "C";
longitude = 18.52;
lattitude = 73.85;
};
};
extraComponents = [
"analytics"
"default_config"
"esphome"
"met"
];
customComponents = with pkgs.home-assistant-custom-components; [
prometheus_sensor
];
2023-12-25 23:35:43 +05:30
lovelaceConfigWritable = true; # remove once setup
2023-12-25 23:29:51 +05:30
lovelaceConfig = {
title = "My Awesome Home";
views = [
{
title = "Example";
cards = [
{
type = "markdown";
title = "Lovelace";
content = "Welcome to your **Lovelace UI**.";
}
];
}
];
};
customLovelaceModules = with pkgs.home-assistant-custom-lovelace-modules; [
mini-graph-card
mini-media-player
];
};
}