44 lines
879 B
Nix
44 lines
879 B
Nix
{ pkgs, ... }:
|
|
{
|
|
# Enable the Home Assistant service
|
|
services.home-assistant = {
|
|
enable = true;
|
|
configWritable = true;
|
|
config = null;
|
|
extraPackages = python3Packages: with pkgs.python3Packages; [
|
|
gtts
|
|
bellows
|
|
radios
|
|
paho-mqtt
|
|
zha-quirks
|
|
pyunifiprotect
|
|
zigpy-deconz
|
|
unifi-discovery
|
|
];
|
|
customComponents = with pkgs.home-assistant-custom-components; [
|
|
];
|
|
};
|
|
|
|
# Enable the mosquitto MQTT broker
|
|
services.mosquitto = {
|
|
enable = true;
|
|
persistence = true;
|
|
listeners = [
|
|
{
|
|
acl = [ "pattern readwrite #" ];
|
|
omitPasswordAuth = true;
|
|
settings.allow_anonymous = true;
|
|
}
|
|
];
|
|
};
|
|
|
|
# Enable the zigbee2mqtt service
|
|
services.zigbee2mqtt = {
|
|
enable = true;
|
|
settings = {
|
|
permit_join = true;
|
|
serial.port = "/dev/ttyUSB0";
|
|
};
|
|
};
|
|
}
|