补齐流水线维护退出选项与停服公告

Full 发布全程保持维护并在最后按选项退出
API Deploy 支持成功后保留维护并补齐回归门禁
新增停服公告维护页并同步运维文档
This commit is contained in:
2026-07-12 21:24:17 +08:00
parent 71811f04c3
commit 51740c021b
9 changed files with 328 additions and 5 deletions
+20
View File
@@ -36,6 +36,7 @@ console.log('[check:production-api-deploy] OK');
function main() {
assertDeployCopiesPingoraDirectReleaseDependencies();
assertSuccessfulDeployCanKeepMaintenance();
assertDeployRestartsActivePingoraWhenArtifactIncluded();
assertDeployStartsInactivePingoraWhenArtifactIncluded();
assertDeployRejectsPingoraDirectEntryWhenArtifactIncluded();
@@ -79,6 +80,22 @@ function main() {
assertMissingPingoraCanaryAccessLogParityFails();
}
function assertSuccessfulDeployCanKeepMaintenance() {
const fixture = prepareFixture('keep-maintenance-after-success');
const result = runDeploy(fixture, { keepMaintenance: true });
assertStatus(result, 0, '显式保持维护时完整 fixture 应部署成功。');
if (result.status !== 0) {
return;
}
assertMaintenanceKept(fixture, '显式要求成功部署后保持维护');
assertIncludes(
result.stdout,
'按参数保持维护模式',
'成功部署并保持维护时必须输出明确状态。',
);
}
function readOptionalCommandsLog(fixture) {
if (!existsSync(fixture.commandsLog)) {
return '';
@@ -1666,6 +1683,9 @@ function runDeploy(fixture, options = {}) {
if (options.requirePingoraGateway) {
args.push('--require-pingora-gateway');
}
if (options.keepMaintenance) {
args.push('--keep-maintenance-mode');
}
return spawnSync(
'bash',
args,