refactor: remove legacy dev cd scripts

This commit is contained in:
Codex
2026-05-26 05:31:57 +08:00
parent f3191736fa
commit e6ac2898fe
32 changed files with 56 additions and 11242 deletions
+8 -6
View File
@@ -236,7 +236,7 @@ function assertDurableRuntimeRunbook(value) {
}
}
function assertCloudApiImageRuntimeEntrypoints({ packageJson, ciJson, artifactPublisher, devCdApplySource }) {
function assertCloudApiImageRuntimeEntrypoints({ packageJson, ciJson, artifactPublisher, gitopsRenderSource }) {
const label = "cloud-api image runtime maintenance entrypoints";
for (const expected of [
"COPY internal ./internal",
@@ -250,14 +250,16 @@ function assertCloudApiImageRuntimeEntrypoints({ packageJson, ciJson, artifactPu
"cmd/hwlab-cloud-api/provision.mjs",
"cmd/hwlab-cloud-api/migrate.mjs"
]) {
assertIncludes(devCdApplySource, expected, `${label} DEV CD job command`);
assertIncludes(packageJson.scripts?.check, `node --check ${expected}`, `${label} package check`);
assertIncludes(packageJson.scripts?.check, `node ${expected} --check`, `${label} package runtime check`);
}
for (const expected of ["scripts/g14-artifact-publish.mjs", "runtime-dev", "runtime-prod"]) {
assertIncludes(gitopsRenderSource, expected, `${label} G14 GitOps render source`);
}
assert.equal(
ciJson.commands?.some((command) => command.run === "npm run check"),
ciJson.commands?.some((command) => command.id === "g14-contract-check"),
true,
`${label} CI must run npm run check`
`${label} CI must run the G14 contract check`
);
}
@@ -441,8 +443,8 @@ assertDurableRuntimeRunbook(await readText("docs/reference/dev-runtime-boundary.
assertCloudApiImageRuntimeEntrypoints({
packageJson: await readJSON("package.json"),
ciJson: await readJSON("CI.json"),
artifactPublisher: await readText("scripts/dev-artifact-publish.mjs"),
devCdApplySource: await readText("scripts/src/dev-cd-apply.mjs")
artifactPublisher: await readText("scripts/artifact-publish.mjs"),
gitopsRenderSource: await readText("scripts/g14-gitops-render.mjs")
});
console.log(