From 46b96c364c90e6d256365feda10cb96122044d22 Mon Sep 17 00:00:00 2001 From: Martin Fischer Date: Fri, 26 Dec 2025 10:19:40 +0100 Subject: refactor(ev): make qbittorrent user own /mnt/lib And rename it to library. --- nixos/hosts/ev/default.nix | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) (limited to 'nixos/hosts') diff --git a/nixos/hosts/ev/default.nix b/nixos/hosts/ev/default.nix index 1a50366..5971755 100644 --- a/nixos/hosts/ev/default.nix +++ b/nixos/hosts/ev/default.nix @@ -71,29 +71,38 @@ in users.groups = { kodi = {}; - qbittorrent = {}; + library = {}; }; + systemd.tmpfiles.rules = [ + "d /mnt/lib 2770 library library -" + ]; + users.users = { martin = { isNormalUser = true; extraGroups = [ "networkmanager" "wheel" + + # directory-specific + "library" ]; }; kodi = { isSystemUser = true; group = "kodi"; + extraGroups = ["library"]; home = "/home/kodi"; createHome = true; }; - qbittorrent = { + library = { isSystemUser = true; - group = "qbittorrent"; - home = "/var/lib/qbittorrent"; + group = "library"; + # qbittorrent needs the home + home = "/home/library"; createHome = true; }; }; @@ -128,7 +137,7 @@ in }; qbittorrent = { - user = "qbittorrent"; + user = "library"; webUiPort = ports.qbittorrent; networkNamespace = "se"; }; -- cgit v1.3.1