30 lines
507 B
Nix
30 lines
507 B
Nix
{ ... }:
|
|
let
|
|
port = 1883;
|
|
in
|
|
{
|
|
services.mosquitto = {
|
|
enable = true;
|
|
logType = [ "all" ];
|
|
listeners = [
|
|
{
|
|
address = "0.0.0.0";
|
|
acl = [ "topic readwrite #" ];
|
|
port = port;
|
|
settings = {
|
|
allow_anonymous = true;
|
|
};
|
|
}
|
|
];
|
|
bridges.hackensOrg = {
|
|
topics = [ "# both" ];
|
|
addresses = [
|
|
{
|
|
address = "new.hackens.org";
|
|
}
|
|
];
|
|
};
|
|
};
|
|
networking.firewall.allowedTCPPorts = [ port ];
|
|
}
|
|
|