From 816527d6e063127fa8e9efc24d60d7372339ec49 Mon Sep 17 00:00:00 2001 From: Raito Bezarius Date: Thu, 14 Nov 2024 18:53:51 +0100 Subject: [PATCH] feat: introduce ofborg mass rebuilder With Gerrit support. Signed-off-by: Raito Bezarius --- services/ofborg/default.nix | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/services/ofborg/default.nix b/services/ofborg/default.nix index 98e25c9..2136055 100644 --- a/services/ofborg/default.nix +++ b/services/ofborg/default.nix @@ -27,6 +27,7 @@ in { rabbitmq.enable = mkEnableOption "ofborg AMQP queue"; builder.enable = mkEnableOption "ofborg builder worker"; pastebin.enable = mkEnableOption "ofborg pastebin service"; + mass-rebuilder.enable = mkEnableOption "ofborg evaluator worker for mass rebuilds jobs"; stats.enable = mkEnableOption "ofborg prometheus worker"; package = mkPackageOption pkgs "ofborg" { }; @@ -71,6 +72,14 @@ in { root = "$STATE_DIRECTORY/pastebins"; db = "$STATE_DIRECTORY/db.json"; }; + + # We use Gerrit. + vcs = "Gerrit"; + gerrit = { + instance_uri = "cl.forkos.org"; + ssh_private_key_file = "$CREDENTIALS_DIRECTORY/gerrit-ssh-key"; + ssh_port = 29418; + }; }; } (mkIf cfg.rabbitmq.enable { @@ -98,6 +107,9 @@ in { (mkIf cfg.pastebin.enable { systemd.services.ofborg-pastebin = mkOfborgWorker "pastebin-worker" { }; }) + (mkIf cfg.mass-rebuilder.enable { + systemd.services.ofborg-mass-rebuilder = mkOfborgWorker "mass-rebuilder" { }; + }) (mkIf cfg.builder.enable { systemd.services.ofborg-builder = mkOfborgWorker "builder" { }; }) @@ -109,5 +121,4 @@ in { # systemd.services.ofborg-evaluation-filter = {}; # systemd.services.ofborg-vcs-comment-filter = {}; # systemd.services.ofborg-vcs-comment-poster = {}; - # systemd.services.ofborg-mass-rebuilder = {}; }