add jellyfin to ymir

This commit is contained in:
Osman Faruk Bayram 2025-02-07 15:49:45 +03:00
parent 3c39b49b0e
commit 5d37ced152
3 changed files with 31 additions and 4 deletions

View file

@ -21,12 +21,9 @@
blockBluesky = true; blockBluesky = true;
enableKDE = true; enableKDE = true;
enableTailscale = true; enableTailscale = true;
enableJellyfin = true;
}; };
services.jellyfin = {
enable = true;
openFirewall = true;
};
# Bootloader. # Bootloader.
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;

View file

@ -7,6 +7,7 @@
./fonts.nix ./fonts.nix
./graphical-interface.nix ./graphical-interface.nix
./i18n.nix ./i18n.nix
./jellyfin.nix
./nix-settings.nix ./nix-settings.nix
./secrets.nix ./secrets.nix
./tailscale.nix ./tailscale.nix

29
modules/jellyfin.nix Normal file
View file

@ -0,0 +1,29 @@
{
config,
pkgs,
...
}: {
options = {
myModules.enableJellyfin = {
enable = lib.mkOption {
type = lib.types.bool;
default = false;
description = "Enable Jellyfin media server";
};
};
};
config = lib.mkMerge [
(lib.mkIf config.myModules.enableJellyfin {
services.jellyfin = {
enable = true;
openFirewall = true;
};
networking.firewall.allowedTCPPorts = [8096];
})
];
}