nixos/git-daemon: only create git user if it will be used
This commit is contained in:
@@ -104,14 +104,14 @@ in
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
users.users = optionalAttrs (cfg.user != "git") {
|
||||
users.users = optionalAttrs (cfg.user == "git") {
|
||||
git = {
|
||||
uid = config.ids.uids.git;
|
||||
description = "Git daemon user";
|
||||
};
|
||||
};
|
||||
|
||||
users.groups = optionalAttrs (cfg.group != "git") {
|
||||
users.groups = optionalAttrs (cfg.group == "git") {
|
||||
git.gid = config.ids.gids.git;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user