aboutsummaryrefslogtreecommitdiff
path: root/nixos/hosts
diff options
context:
space:
mode:
authorMartin Fischer <martin@push-f.com>2025-12-29 09:36:20 +0100
committerMartin Fischer <martin@push-f.com>2025-12-29 09:39:37 +0100
commit1ffc0fb9b1d5dfb6658665c13ad13b3378d43fe2 (patch)
tree56cd8db8aa9cfe504bb34d1b998ed378acc26c67 /nixos/hosts
parenta0954dd18b5c61c1382b594e2134ddc001b2980b (diff)
refactor(tente): define gitolite user in main module
Diffstat (limited to 'nixos/hosts')
-rw-r--r--nixos/hosts/tente/default.nix2
-rw-r--r--nixos/hosts/tente/gitolite.nix10
2 files changed, 10 insertions, 2 deletions
diff --git a/nixos/hosts/tente/default.nix b/nixos/hosts/tente/default.nix
index 749f468..ddfa89b 100644
--- a/nixos/hosts/tente/default.nix
+++ b/nixos/hosts/tente/default.nix
@@ -89,6 +89,8 @@ in
gitolite = {
dataDir = gitoliteDataDir;
+ user = "git";
+ group = "git";
};
grafana = {
diff --git a/nixos/hosts/tente/gitolite.nix b/nixos/hosts/tente/gitolite.nix
index c9a7fae..b7fba1a 100644
--- a/nixos/hosts/tente/gitolite.nix
+++ b/nixos/hosts/tente/gitolite.nix
@@ -5,6 +5,12 @@ let
in
{
options.gitolite = {
+ user = lib.mkOption {
+ type = lib.types.str;
+ };
+ group = lib.mkOption {
+ type = lib.types.str;
+ };
dataDir = lib.mkOption {
type = lib.types.str;
};
@@ -14,8 +20,8 @@ in
services.gitolite = {
enable = true;
adminPubkey = ""; # TODO: submit PR to nixpkgs to make this option optional
- user = "git";
- group = "git";
+ user = cfg.user;
+ group = cfg.group;
dataDir = cfg.dataDir;
extraGitoliteRc = ''
$RC{UMASK} = 0027;