From d7f283468a9ddb17fb97d856280a9a018ee134c3 Mon Sep 17 00:00:00 2001 From: Inex Code Date: Sat, 27 Jul 2024 02:26:23 +0300 Subject: [PATCH] try to move forgejo to a slice --- sp-modules/gitea/module.nix | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/sp-modules/gitea/module.nix b/sp-modules/gitea/module.nix index ca7d012..7f08864 100644 --- a/sp-modules/gitea/module.nix +++ b/sp-modules/gitea/module.nix @@ -146,7 +146,14 @@ in }; }; }; - systemd.services.forgejo.unitConfig.RequiresMountsFor = - lib.mkIf sp.useBinds "/volumes/${cfg.location}/gitea"; + systemd.services.forgejo = { + unitConfig.RequiresMountsFor = lib.mkIf sp.useBinds "/volumes/${cfg.location}/gitea"; + serviceConfig = { + Slice = "gitea.slice"; + }; + }; + systemd.slices.gitea = { + description = "Forgejo service slice"; + }; }; }