feat: add HWLAB G14 lane profile config
This commit is contained in:
@@ -4,7 +4,7 @@ import { createHash, randomBytes } from "node:crypto";
|
||||
import { repoRoot, rootPath, type Config } from "./config";
|
||||
import { runCommand } from "./command";
|
||||
import { readJob, startJob } from "./jobs";
|
||||
import { hwlabRuntimeLaneIds, hwlabRuntimeLaneSpec, isHwlabRuntimeLane, type HwlabRuntimeLane, type HwlabRuntimeLaneSpec } from "./hwlab-g14-lanes";
|
||||
import { hwlabRequiredNoProxyEntries, hwlabRuntimeLaneConfigPath, hwlabRuntimeLaneIds, hwlabRuntimeLaneSpec, isHwlabRuntimeLane, type HwlabRuntimeLane, type HwlabRuntimeLaneSpec } from "./hwlab-g14-lanes";
|
||||
|
||||
const HWLAB_REPO = "pikasTech/HWLAB";
|
||||
const G14_SOURCE_BRANCH = "G14";
|
||||
@@ -3208,7 +3208,7 @@ function deleteV02ObsoleteCronJobs(dryRun: boolean): CommandJsonResult {
|
||||
], 60_000);
|
||||
}
|
||||
|
||||
function runtimeLanePipelineRunManifest(spec: HwlabRuntimeLaneSpec, sourceCommit: string): Record<string, unknown> {
|
||||
export function runtimeLanePipelineRunManifest(spec: HwlabRuntimeLaneSpec, sourceCommit: string): Record<string, unknown> {
|
||||
const pipelineRun = runtimeLanePipelineRunName(spec, sourceCommit);
|
||||
return {
|
||||
apiVersion: "tekton.dev/v1",
|
||||
@@ -3225,6 +3225,10 @@ function runtimeLanePipelineRunManifest(spec: HwlabRuntimeLaneSpec, sourceCommit
|
||||
annotations: {
|
||||
"hwlab.pikastech.local/source-branch": spec.sourceBranch,
|
||||
"hwlab.pikastech.local/gitops-branch": spec.gitopsBranch,
|
||||
"hwlab.pikastech.local/node": spec.nodeId,
|
||||
"hwlab.pikastech.local/network-profile": spec.networkProfileId,
|
||||
"hwlab.pikastech.local/download-profile": spec.downloadProfileId,
|
||||
"hwlab.pikastech.local/no-proxy-required": hwlabRequiredNoProxyEntries().join(","),
|
||||
"hwlab.pikastech.local/triggered-by": "unidesk-cli",
|
||||
},
|
||||
},
|
||||
@@ -3607,6 +3611,9 @@ function runtimeLaneControlPlaneStatus(spec: HwlabRuntimeLaneSpec, target: V02Co
|
||||
sourceCommit,
|
||||
expected: {
|
||||
sourceRepo: spec.cicdRepo,
|
||||
configPath: hwlabRuntimeLaneConfigPath(),
|
||||
node: spec.nodeId,
|
||||
nodeRoute: spec.nodeRoute,
|
||||
workspace: spec.workspace,
|
||||
branch: spec.sourceBranch,
|
||||
namespace: CI_NAMESPACE,
|
||||
@@ -3616,6 +3623,14 @@ function runtimeLaneControlPlaneStatus(spec: HwlabRuntimeLaneSpec, target: V02Co
|
||||
argoApplication: spec.app,
|
||||
gitopsBranch: spec.gitopsBranch,
|
||||
runtimePath: spec.runtimePath,
|
||||
networkProfile: {
|
||||
id: spec.networkProfileId,
|
||||
httpProxy: spec.networkProfile.proxy.http,
|
||||
noProxy: spec.networkProfile.proxy.noProxy.join(","),
|
||||
dockerBuildHttpProxy: spec.networkProfile.dockerBuildProxy.http,
|
||||
dockerBuildNoProxy: spec.networkProfile.dockerBuildProxy.noProxy.join(","),
|
||||
},
|
||||
downloadProfile: spec.downloadProfile,
|
||||
},
|
||||
sourceHead: {
|
||||
ok: shellSectionOk(sections.sourceHead),
|
||||
@@ -8470,6 +8485,7 @@ export function hwlabG14Help(): Record<string, unknown> {
|
||||
repo: HWLAB_REPO,
|
||||
base: G14_SOURCE_BRANCH,
|
||||
v02Base: V02_SOURCE_BRANCH,
|
||||
runtimeLaneConfig: hwlabRuntimeLaneConfigPath(),
|
||||
runtimeLanes: hwlabRuntimeLaneIds(),
|
||||
provider: G14_PROVIDER,
|
||||
workspace: G14_WORKSPACE,
|
||||
@@ -8480,6 +8496,10 @@ export function hwlabG14Help(): Record<string, unknown> {
|
||||
devApplication: DEV_APP,
|
||||
v02Application: V02_APP,
|
||||
v03Application: hwlabRuntimeLaneSpec("v03").app,
|
||||
v03Node: hwlabRuntimeLaneSpec("v03").nodeId,
|
||||
v03NetworkProfile: hwlabRuntimeLaneSpec("v03").networkProfileId,
|
||||
v03DownloadProfile: hwlabRuntimeLaneSpec("v03").downloadProfileId,
|
||||
requiredNoProxy: hwlabRequiredNoProxyEntries(),
|
||||
briefIndexIssue: G14_BRIEF_INDEX_ISSUE,
|
||||
observabilityNamespace: G14_OBSERVABILITY_NAMESPACE,
|
||||
prometheusOperatorVersion: G14_PROMETHEUS_OPERATOR_VERSION,
|
||||
|
||||
Reference in New Issue
Block a user