fix(ci): deploy on target environment agents

This commit is contained in:
2026-08-22 17:43:20 +08:00
parent e398f1f7e0
commit 232c2657f1
2 changed files with 36 additions and 47 deletions
@@ -37,10 +37,12 @@ test('production deployments cannot skip tests', () => {
test('Java builds use the shared builder pool and serialize incremental target deployments', () => {
assert.match(pipeline, /agent \{ label 'java-builder' \}/)
assert.match(pipeline, /\['development', 'test'\]\.contains\(params\.ENVIRONMENT\)/)
assert.match(pipeline, /\['master', 'built-in'\]\.contains\(env\.NODE_NAME\)/)
assert.match(pipeline, /params\.ENVIRONMENT == 'development' \? 'java-dev' : 'java-test'/)
assert.match(pipeline, /'TARGET_IS_LOCAL=true'/)
assert.match(pipeline, /String deployLock = "firstleg-\$\{params\.ENVIRONMENT\}-deploy"/)
assert.match(pipeline, /lock\(resource: deployLock, inversePrecedence: true\)/)
assert.match(pipeline, /deploy-built-service\.sh/)
assert.doesNotMatch(pipeline, /dev_deploy|test_deploy|TARGET_SSH_KEY/)
assert.match(directDeployScript, /docker pull "\$IMAGE"/)
assert.match(directDeployScript, /run_ssh docker pull "\$IMAGE"/)
assert.doesNotMatch(directDeployScript, /docker save "\$IMAGE"/)