mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-10-31 22:51:22 +00:00
nixos/tautulli: add option to open firewall
This commit is contained in:
parent
bd2c13dc11
commit
feba340314
@ -32,6 +32,12 @@ in
|
||||
description = lib.mdDoc "TCP port where Tautulli listens.";
|
||||
};
|
||||
|
||||
openFirewall = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = "Open ports in the firewall for Tautulli.";
|
||||
};
|
||||
|
||||
user = mkOption {
|
||||
type = types.str;
|
||||
default = "plexpy";
|
||||
@ -74,6 +80,8 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = mkIf cfg.openFirewall [ cfg.port ];
|
||||
|
||||
users.users = mkIf (cfg.user == "plexpy") {
|
||||
plexpy = { group = cfg.group; uid = config.ids.uids.plexpy; };
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user