metrics-reporter-prometheus: init

This commit is contained in:
Luke Granger-Brown 2024-07-11 00:14:56 +01:00
parent eb589c659e
commit 23dd318e67
2 changed files with 20 additions and 0 deletions

View file

@ -14,11 +14,13 @@ lib.makeScope pkgs.newScope (self: {
plugins = {
code-owners = self.callPackage ./plugins/code-owners { };
oauth = self.callPackage ./plugins/oauth { };
metrics-reporter-prometheus = self.callPackage ./plugins/metrics-reporter-prometheus { };
};
ci = pkgs.linkFarm "gerrit-ci" [
{ name = "gerrit"; path = self.gerrit; }
{ name = "code-owners.jar"; path = self.plugins.code-owners; }
{ name = "oauth.jar"; path = self.plugins.oauth; }
{ name = "metrics-reporter-prometheus.jar"; path = self.plugins.metrics-reporter-prometheus; }
];
})

View file

@ -0,0 +1,18 @@
# SPDX-FileCopyrightText: 2024 The nix-gerrit Authors <git@lukegb.com>
# SPDX-License-Identifier: MIT
{ buildGerritBazelPlugin, fetchgit }:
buildGerritBazelPlugin rec {
name = "metrics-reporter-prometheus";
version = "f2ee1d";
src = fetchgit {
url = "https://gerrit.googlesource.com/plugins/metrics-reporter-prometheus";
rev = "f2ee1de665281596ae300144243fcf94bf6f1f7d";
hash = "sha256-iUFzSXKIKBdZBZMpZiejkEEXXI20wTJQRYkufc/YjOM=";
};
depsHash = "sha256-hxnQlzzVQ15fyVo613FOsHlZZgOL1lBKOgqEGBoc7To=";
postOverlayPlugin = ''
cp "${src}/external_plugin_deps.bzl" "$out/plugins/external_plugin_deps.bzl"
'';
}