feat(*): initialize new Snix infrastructure
Co-Authored-By: edef <edef@edef.eu> Co-Authored-by: Ryan Lahfa <raito@lix.systems> Change-Id: Ica1cda177a236814de900f50a8a61d288f58f519
This commit is contained in:
parent
067eff3427
commit
a52ea3675c
124 changed files with 27723 additions and 1631 deletions
|
|
@ -1,8 +1,9 @@
|
|||
{ depot, pkgs, lib, ... }:
|
||||
{ gerrit }:
|
||||
|
||||
let
|
||||
classPath = lib.concatStringsSep ":" [
|
||||
"${depot.third_party.gerrit}/share/api/extension-api_deploy.jar"
|
||||
"${gerrit}/share/api/extension-api_deploy.jar"
|
||||
];
|
||||
in
|
||||
pkgs.stdenvNoCC.mkDerivation rec {
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
// vim: set noai ts=2 sw=2 et: */
|
||||
|
||||
// This is a read-only Buildkite token: it was generated by lukegb@, and has
|
||||
// This is a read-only Buildkite token: it was generated and installed by flokli@ and has
|
||||
// read_builds, read_build_logs, and read_pipelines permissions.
|
||||
const BUILDKITE_TOKEN = 'a150658fb61062e432f13a032962d70fa9352088';
|
||||
const BUILDKITE_TOKEN = 'bkua_fbb743ba597d89caf522876289705f6571bb599d';
|
||||
|
||||
function encodeParams(p) {
|
||||
const pieces = [];
|
||||
|
|
@ -77,25 +77,25 @@ function jobStateToCheckRunStatus(state) {
|
|||
return status;
|
||||
}
|
||||
|
||||
const tvlChecksProvider = {
|
||||
const snixChecksProvider = {
|
||||
async fetch(change) {
|
||||
let {patchsetSha, repo} = change;
|
||||
|
||||
const experiments = window.ENABLED_EXPERIMENTS || [];
|
||||
if (experiments.includes("UiFeature__tvl_check_debug")) {
|
||||
if (experiments.includes("UiFeature__snix_check_debug")) {
|
||||
patchsetSha = '76692104f58b849b1503a8d8a700298003fa7b5f';
|
||||
repo = 'depot';
|
||||
repo = 'snix';
|
||||
}
|
||||
|
||||
if (repo !== 'depot') {
|
||||
// We only handle TVL's depot at the moment.
|
||||
if (repo !== 'snix') {
|
||||
// We only handle snix's depot at the moment.
|
||||
return {responseCode: 'OK'};
|
||||
}
|
||||
|
||||
const params = {
|
||||
commit: patchsetSha,
|
||||
};
|
||||
const url = `https://api.buildkite.com/v2/organizations/tvl/pipelines/depot/builds?${encodeParams(params)}`;
|
||||
const url = `https://api.buildkite.com/v2/organizations/snix/pipelines/snix/builds?${encodeParams(params)}`;
|
||||
const resp = await fetch(url, {
|
||||
headers: {
|
||||
Authorization: `Bearer ${BUILDKITE_TOKEN}`,
|
||||
|
|
@ -183,7 +183,7 @@ const tvlChecksProvider = {
|
|||
};
|
||||
|
||||
Gerrit.install(plugin => {
|
||||
console.log('TVL plugin initialising');
|
||||
console.log('snix plugin initialising');
|
||||
|
||||
plugin.checks().register(tvlChecksProvider);
|
||||
plugin.checks().register(snixChecksProvider);
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue