Add mqtt service to magnesium
This commit is contained in:
parent
7a8c0fc768
commit
7ce95063c8
2 changed files with 16 additions and 0 deletions
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
imports = [
|
||||
./coturn.nix
|
||||
./mosquitto.nix
|
||||
./public-ip-tunnel.nix
|
||||
./webserver.nix
|
||||
];
|
||||
|
|
|
|||
15
hosts/magnesium/services/mosquitto.nix
Normal file
15
hosts/magnesium/services/mosquitto.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
let port = 1883;
|
||||
in
|
||||
{
|
||||
services.mosquitto = {
|
||||
enable = true;
|
||||
persistence = true;
|
||||
listeners = [
|
||||
{
|
||||
port = port;
|
||||
}
|
||||
];
|
||||
};
|
||||
networking.firewall.allowedTCPPorts = [ port ];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue