From 92cdc5df5ebe3fecbc59d0ec6a901fda28067862 Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Thu, 26 May 2022 09:11:31 -0700 Subject: feat(gerrit): use OAUTH for authentication --- modules/services/gerrit/default.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'modules/services/gerrit') diff --git a/modules/services/gerrit/default.nix b/modules/services/gerrit/default.nix index df285d3..9db7b46 100644 --- a/modules/services/gerrit/default.nix +++ b/modules/services/gerrit/default.nix @@ -18,6 +18,8 @@ in { builtinPlugins = [ "download-commands" "hooks" ]; jvmHeapLimit = "4g"; + plugins = [ owners oauth ]; + settings = { core.packedGitLimit = "100m"; log.jsonLogging = true; @@ -40,6 +42,14 @@ in { # Receiving email is not currently supported. sendemail = { enable = false; }; }; + + auth.type = "OAUTH"; + + # users can change their emails + oauth.allowRegisterNewEmail = true; + + # use gerrit HTTP password + auth.gitBasicAuthPolicy = "HTTP"; }; systemd.services.gerrit = { -- cgit 1.4.1