From 7fbaa7b8752fdb7f12896521bb0f1a0e4d8448a6 Mon Sep 17 00:00:00 2001 From: Felix Tenley Date: Sat, 13 Mar 2021 12:55:00 +0100 Subject: [PATCH] feat(rpi4): add kodi --- rpi4.nix | 1 + services/kodi.nix | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 services/kodi.nix diff --git a/rpi4.nix b/rpi4.nix index 8978079..f002a8b 100644 --- a/rpi4.nix +++ b/rpi4.nix @@ -8,6 +8,7 @@ with builtins; { ./system/nix.nix ./system/i18n.nix ./services/syncthing/rpi4.nix + ./services/kodi.nix ./services/jellyfin.nix ./services/etebase.nix ./services/home-assistant.nix diff --git a/services/kodi.nix b/services/kodi.nix new file mode 100644 index 0000000..48c0900 --- /dev/null +++ b/services/kodi.nix @@ -0,0 +1,24 @@ +{ config, pkgs, ... }: + +{ + services.xserver.enable = true; + services.xserver.desktopManager.kodi.enable = true; + services.xserver.displayManager.autoLogin.enable = true; + services.xserver.displayManager.autoLogin.user = "kodi"; + + users.extraUsers.kodi.isNormalUser = true; + + networking.firewall = { + allowedTCPPorts = [ 8080 ]; + allowedUDPPorts = [ 8080 ]; + }; + + environment.systemPackages = [ + (pkgs.kodi.override { + plugins = with pkgs.kodiPlugins; [ + advanced-launcher + pkgs.nur.repos.marzipankaiser.kodiPlugins.netflix + ]; + }) + ]; +}