diff options
author | Vincent Ambo <mail@tazj.in> | 2021-11-29T15·53+0300 |
---|---|---|
committer | Vincent Ambo <mail@tazj.in> | 2021-12-02T10·10+0300 |
commit | ee635d4645126d0821e75fe71b4e56ec7e119eaa (patch) | |
tree | 7f6b9dd7cf64a6a803a8b8a26aa22348d22c41ba /ops/modules/monorepo-gerrit.nix | |
parent | 168114df525f7f9b5fe5377e0a66e213b779a723 (diff) |
chore(ops/modules): Configure besadii call sites to load config r/3134
On whitby, the besadii config will live in /etc/secrets/besadii.json. This CL updates the call sites to pass this config path to besadii so that it can load Sourcegraph configuration. Change-Id: Ia139b9fa3b827e7a5f2386214390acc6fe19a75a
Diffstat (limited to 'ops/modules/monorepo-gerrit.nix')
-rw-r--r-- | ops/modules/monorepo-gerrit.nix | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/ops/modules/monorepo-gerrit.nix b/ops/modules/monorepo-gerrit.nix index 714aeeaa6ef1..d9507db56e92 100644 --- a/ops/modules/monorepo-gerrit.nix +++ b/ops/modules/monorepo-gerrit.nix @@ -3,10 +3,16 @@ let cfg = config.services.gerrit; + + besadiiWithConfig = pkgs.writeShellScript "besadii-whitby" '' + export BESADII_CONFIG=/etc/secrets/besadii.json + exec ${depot.ops.besadii}/bin/besadii + ''; + gerritHooks = pkgs.runCommandNoCC "gerrit-hooks" {} '' mkdir -p $out - ln -s ${depot.ops.besadii}/bin/besadii $out/change-merged - ln -s ${depot.ops.besadii}/bin/besadii $out/patchset-created + ln -s ${besadiiWithConfig} $out/change-merged + ln -s ${besadiiWithConfig} $out/patchset-created ''; in { services.gerrit = { |