nixos/gitolite: don't leak nix store hash into gitolite-admin username/key
It doesn't look good when the initial admin user is named "<hash>-gitolite-admin" and the key stored as "<hash>-gitolite-admin.pub". Instead, make it simply "gitolite-admin" and "gitolite-admin.pub".
This commit is contained in:
parent
58c2967c46
commit
6b9ee30672
@ -4,7 +4,8 @@ with lib;
|
|||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.services.gitolite;
|
cfg = config.services.gitolite;
|
||||||
pubkeyFile = pkgs.writeText "gitolite-admin.pub" cfg.adminPubkey;
|
# Use writeTextDir to not leak Nix store hash into file name
|
||||||
|
pubkeyFile = (pkgs.writeTextDir "gitolite-admin.pub" cfg.adminPubkey) + "/gitolite-admin.pub";
|
||||||
hooks = lib.concatMapStrings (hook: "${hook} ") cfg.commonHooks;
|
hooks = lib.concatMapStrings (hook: "${hook} ") cfg.commonHooks;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user