jellyfin instead of plex
This commit is contained in:
parent
1dc870e664
commit
431db062bc
3 changed files with 73 additions and 15 deletions
|
|
@ -47,7 +47,9 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
nas = {
|
nas =
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
deployment.targetHost = nasIp;
|
deployment.targetHost = nasIp;
|
||||||
imports = [ ../system/svalbard/configuration.nix ];
|
imports = [ ../system/svalbard/configuration.nix ];
|
||||||
networking.wireless.networks.N904.pskRaw = (
|
networking.wireless.networks.N904.pskRaw = (
|
||||||
|
|
@ -61,5 +63,10 @@ in
|
||||||
'';
|
'';
|
||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [ 2049 ];
|
networking.firewall.allowedTCPPorts = [ 2049 ];
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
flood
|
||||||
|
rtorrent
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
34
nix/home/programs/jellyfin/default.nix
Normal file
34
nix/home/programs/jellyfin/default.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
||||||
|
{
|
||||||
|
networking.firewall = {
|
||||||
|
allowedTCPPorts = [
|
||||||
|
# jellyfin frontend
|
||||||
|
8096
|
||||||
|
8920
|
||||||
|
#nginx
|
||||||
|
80
|
||||||
|
];
|
||||||
|
allowedUDPPorts = [
|
||||||
|
# jellyfin discovery
|
||||||
|
1900
|
||||||
|
7359
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
services.jellyfin.enable = true;
|
||||||
|
|
||||||
|
services.nginx = {
|
||||||
|
enable = true;
|
||||||
|
recommendedGzipSettings = true;
|
||||||
|
recommendedOptimisation = true;
|
||||||
|
recommendedProxySettings = true;
|
||||||
|
recommendedTlsSettings = true;
|
||||||
|
|
||||||
|
virtualHosts."mediaserver" = {
|
||||||
|
# http2 can more performant for streaming: https://blog.cloudflare.com/introducing-http2/
|
||||||
|
http2 = true;
|
||||||
|
locations."/" = {
|
||||||
|
proxyPass = "http://localhost:8096";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
# your system. Help is available in the configuration.nix(5) man page
|
# your system. Help is available in the configuration.nix(5) man page
|
||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
imports =
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
./glibc-locale-paths.nix
|
./glibc-locale-paths.nix
|
||||||
../common/users.nix
|
../common/users.nix
|
||||||
../../home/programs/plex
|
../../home/programs/jellyfin
|
||||||
];
|
];
|
||||||
|
|
||||||
# Use the systemd-boot EFI boot loader.
|
# Use the systemd-boot EFI boot loader.
|
||||||
|
|
@ -79,6 +79,23 @@
|
||||||
|
|
||||||
services.xserver.layout = "us";
|
services.xserver.layout = "us";
|
||||||
|
|
||||||
|
nixpkgs.config.packageOverrides = pkgs: {
|
||||||
|
vaapiIntel = pkgs.vaapiIntel.override { enableHybridCodec = true; };
|
||||||
|
};
|
||||||
|
hardware.opengl = {
|
||||||
|
enable = true;
|
||||||
|
extraPackages = with pkgs; [
|
||||||
|
intel-media-driver
|
||||||
|
vaapiIntel
|
||||||
|
vaapiVdpau
|
||||||
|
libvdpau-va-gl
|
||||||
|
intel-compute-runtime # OpenCL filter support (hardware tonemapping and subtitle burn-in)
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# 2. override default hardening measure from NixOS - this is default since 22.05
|
||||||
|
systemd.services.jellyfin.serviceConfig.PrivateDevices = lib.mkForce false;
|
||||||
|
|
||||||
# Enable touchpad support.
|
# Enable touchpad support.
|
||||||
# services.xserver.libinput.enable = true;
|
# services.xserver.libinput.enable = true;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue