From 9ed03f2103651846807aa0bcd5c4e980eda1d5c9 Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Fri, 10 Jan 2020 22:00:09 +0100 Subject: [PATCH] nixos/paperless: fix tmpfiles rules Previously, the service expected the paperless user to have a group with the user's name. This is not necessarily the case for custom users. --- nixos/modules/services/misc/paperless.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nixos/modules/services/misc/paperless.nix b/nixos/modules/services/misc/paperless.nix index 119dcebe019..bfaf760fb83 100644 --- a/nixos/modules/services/misc/paperless.nix +++ b/nixos/modules/services/misc/paperless.nix @@ -123,9 +123,9 @@ in config = mkIf cfg.enable { systemd.tmpfiles.rules = [ - "d '${cfg.dataDir}' - ${cfg.user} ${cfg.user} - -" + "d '${cfg.dataDir}' - ${cfg.user} ${config.users.users.${cfg.user}.group} - -" ] ++ (optional cfg.consumptionDirIsPublic - "d '${cfg.consumptionDir}' 777 ${cfg.user} ${cfg.user} - -" + "d '${cfg.consumptionDir}' 777 - - - -" # If the consumption dir is not created here, it's automatically created by # 'manage' with the default permissions. );