From 51bed7030fea8f3242a05e0d7f385152e7740d64 Mon Sep 17 00:00:00 2001 From: Savyasachee Jha Date: Thu, 19 Dec 2024 20:13:58 +0530 Subject: [PATCH] nixos/firefly-iii: Improved cache clearing --- nixos/modules/services/web-apps/firefly-iii.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/nixos/modules/services/web-apps/firefly-iii.nix b/nixos/modules/services/web-apps/firefly-iii.nix index 92b4cb2268857..42d6cdcb06b37 100644 --- a/nixos/modules/services/web-apps/firefly-iii.nix +++ b/nixos/modules/services/web-apps/firefly-iii.nix @@ -31,6 +31,7 @@ let ${lib.optionalString ( cfg.settings.DB_CONNECTION == "sqlite" ) "touch ${cfg.dataDir}/storage/database/database.sqlite"} + ${artisan} optimize:clear rm ${cfg.dataDir}/cache/*.php ${artisan} package:discover ${artisan} firefly-iii:upgrade-database @@ -318,6 +319,7 @@ in } // commonServiceConfig; unitConfig.JoinsNamespaceOf = "phpfpm-firefly-iii.service"; restartTriggers = [ cfg.package ]; + partOf = [ "phpfpm-firefly-iii.service" ]; }; systemd.services.firefly-iii-cron = {