diff options
author | David McFarland <corngood@gmail.com> | 2020-12-29 16:46:54 -0400 |
---|---|---|
committer | David McFarland <corngood@gmail.com> | 2020-12-31 09:44:36 -0400 |
commit | 6c0a704e0e613fb50846aefa151e88c954b60f9f (patch) | |
tree | 86456a424e905b914fb6b3509ce0f2c1de7a4b51 | |
parent | 0597dcb0c570f365c363645f6d7eac6d0b3d811c (diff) | |
download | nixpkgs-6c0a704e0e613fb50846aefa151e88c954b60f9f.tar nixpkgs-6c0a704e0e613fb50846aefa151e88c954b60f9f.tar.gz nixpkgs-6c0a704e0e613fb50846aefa151e88c954b60f9f.tar.bz2 nixpkgs-6c0a704e0e613fb50846aefa151e88c954b60f9f.tar.lz nixpkgs-6c0a704e0e613fb50846aefa151e88c954b60f9f.tar.xz nixpkgs-6c0a704e0e613fb50846aefa151e88c954b60f9f.tar.zst nixpkgs-6c0a704e0e613fb50846aefa151e88c954b60f9f.zip |
jellyfin: add openFirewall option
-rw-r--r-- | nixos/modules/services/misc/jellyfin.nix | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/nixos/modules/services/misc/jellyfin.nix b/nixos/modules/services/misc/jellyfin.nix index 6a47dc3628f..64b774a220b 100644 --- a/nixos/modules/services/misc/jellyfin.nix +++ b/nixos/modules/services/misc/jellyfin.nix @@ -29,6 +29,16 @@ in default = "jellyfin"; description = "Group under which jellyfin runs."; }; + + openFirewall = mkOption { + type = types.bool; + default = false; + description = '' + Open the default ports in the firewall for the media server. The + HTTP/HTTPS ports can be changed in the Web UI, so this option should + only be used if they are unchanged. + ''; + }; }; }; @@ -104,6 +114,12 @@ in jellyfin = {}; }; + networking.firewall = mkIf cfg.openFirewall { + # from https://jellyfin.org/docs/general/networking/index.html + allowedTCPPorts = [ 8096 8920 ]; + allowedUDPPorts = [ 1900 7359 ]; + }; + }; meta.maintainers = with lib.maintainers; [ minijackson ]; |