nixos/grocy: enforce data directory presence
In the case of mounted directories, systemd needs to know that this script depends on this path to add the adequate dependency.
This commit is contained in:
@@ -216,6 +216,7 @@ in
|
||||
systemd.services.grocy-setup = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
before = [ "phpfpm-grocy.service" ];
|
||||
unitConfig.RequiresMountsFor = [ cfg.dataDir ];
|
||||
script = ''
|
||||
rm -rf ${cfg.dataDir}/viewcache/*
|
||||
'';
|
||||
|
||||
Reference in New Issue
Block a user