grocy: clear viewcache before start

This commit is contained in:
Ember Keske 2023-08-19 19:45:28 +02:00
parent 0b1ef8ea9e
commit 0138e327c1

View File

@ -130,6 +130,16 @@ in {
};
};
# After an update of grocy, the viewcache needs to be deleted. Otherwise grocy will not work
# https://github.com/grocy/grocy#how-to-update
systemd.services.grocy-setup = {
wantedBy = [ "multi-user.target" ];
before = [ "phpfpm-grocy.service" ];
script = ''
rm -rf ${cfg.dataDir}/viewcache/*
'';
};
services.nginx = {
enable = true;
virtualHosts."${cfg.hostName}" = mkMerge [