3
0
Fork 0
forked from mirrors/nixpkgs

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.
This commit is contained in:
Erik Arvstedt 2020-01-10 22:00:09 +01:00 committed by Alyssa Ross
parent 5ad5d2321f
commit 9ed03f2103

View file

@ -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.
);