From 4c4f73c0ebffdf5b4b81b4c4b0ad861281d4222a Mon Sep 17 00:00:00 2001 From: pvgoran Date: Tue, 12 Sep 2017 02:03:51 +0700 Subject: [PATCH] services.gitolite: Add RequiresMountsFor unit option ... ... to ensure that the filesystem where `dataDir` resides is mounted when we do initialization or upgrade. --- nixos/modules/services/misc/gitolite.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/nixos/modules/services/misc/gitolite.nix b/nixos/modules/services/misc/gitolite.nix index 5012bed0c422..3b65bbab571c 100644 --- a/nixos/modules/services/misc/gitolite.nix +++ b/nixos/modules/services/misc/gitolite.nix @@ -70,6 +70,7 @@ in systemd.services."gitolite-init" = { description = "Gitolite initialization"; wantedBy = [ "multi-user.target" ]; + unitConfig.RequiresMountsFor = cfg.dataDir; serviceConfig.User = "${cfg.user}"; serviceConfig.Type = "oneshot";