Skip to content

Commit

Permalink
Add kodi
Browse files Browse the repository at this point in the history
  • Loading branch information
arunoruto committed Nov 23, 2024
1 parent d7a2803 commit b528e15
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions modules/nixos/desktop/kodi.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
config,
pkgs,
lib,
...
}: let
kodi-user = "kodi";
in {
options = {
kodi.enable = lib.mkEnableOption "Use KODi as a desktop environment";
};

config = lib.mkIf config.kodi.enable {
services = {
xserver = {
desktopManager.kodi = {
enable = true;
package = pkgs.kodi.withPackages (pkgs:
with pkgs; [
jellycon
netflix
youtube
]);
};
displayManager.lightdm.greeter.enable = false;
};
displayManager = {
autoLogin = {
enable = true;
user = kodi-user;
};
};
};

# Define a user account
users.extraUsers.${kodi-user}.isNormalUser = true;

networking.firewall = {
allowedTCPPorts = [8080];
allowedUDPPorts = [8080];
};
};
}

0 comments on commit b528e15

Please sign in to comment.