mirror of
https://git.sr.ht/~magic_rb/cluster
synced 2024-12-07 07:24:47 +01:00
312452014f
Signed-off-by: Magic_RB <magic_rb@redalder.org>
33 lines
701 B
Nix
33 lines
701 B
Nix
{ nglib, nixpkgs }:
|
|
nglib.makeSystem {
|
|
system = "x86_64-linux";
|
|
name = "nixng-mosquitto";
|
|
inherit nixpkgs;
|
|
config = ({ pkgs, config, nglib, ... }:
|
|
let
|
|
ids = config.ids;
|
|
in
|
|
{
|
|
config = {
|
|
dumb-init = {
|
|
enable = true;
|
|
type.services = { };
|
|
};
|
|
|
|
init.services.mosquitto = {
|
|
shutdownOnExit = true;
|
|
};
|
|
|
|
services.mosquitto = {
|
|
enable = true;
|
|
config = {
|
|
listener =
|
|
["1883 0.0.0.0"
|
|
({ password_file = "/secrets/mqtt_password";
|
|
})
|
|
];
|
|
};
|
|
};
|
|
};
|
|
});
|
|
}
|