diff options
author | Jörg Thalheim <Mic92@users.noreply.github.com> | 2017-09-10 14:34:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-10 14:34:29 +0100 |
commit | 7641d0e335662952b1d95dbe3c6613a94348e0ea (patch) | |
tree | 92bf06806297a498be7a7ba4b70ecb4c06aa2806 /nixos | |
parent | ba66db5fb1d3b9712c9209d89a92aece306c0565 (diff) | |
parent | c7dd5e146bd6cdaacffaa681e56dbd1c916ace17 (diff) | |
download | nixpkgs-7641d0e335662952b1d95dbe3c6613a94348e0ea.tar nixpkgs-7641d0e335662952b1d95dbe3c6613a94348e0ea.tar.gz nixpkgs-7641d0e335662952b1d95dbe3c6613a94348e0ea.tar.bz2 nixpkgs-7641d0e335662952b1d95dbe3c6613a94348e0ea.tar.lz nixpkgs-7641d0e335662952b1d95dbe3c6613a94348e0ea.tar.xz nixpkgs-7641d0e335662952b1d95dbe3c6613a94348e0ea.tar.zst nixpkgs-7641d0e335662952b1d95dbe3c6613a94348e0ea.zip |
Merge pull request #29171 from vaibhavsagar/znc-open-firewall
znc: open firewall with configured port
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/modules/services/networking/znc.nix | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/nixos/modules/services/networking/znc.nix b/nixos/modules/services/networking/znc.nix index c408899a322..763843fdec0 100644 --- a/nixos/modules/services/networking/znc.nix +++ b/nixos/modules/services/networking/znc.nix @@ -276,6 +276,14 @@ in ''; }; + openFirewall = mkOption { + type = types.bool; + default = false; + description = '' + Whether to open ports in the firewall for ZNC. + ''; + }; + passBlock = mkOption { example = defaultPassBlock; type = types.string; @@ -350,6 +358,10 @@ in config = mkIf cfg.enable { + networking.firewall = mkIf cfg.openFirewall { + allowedTCPPorts = [ cfg.port ]; + }; + systemd.services.znc = { description = "ZNC Server"; wantedBy = [ "multi-user.target" ]; |