ci: verify agent harness workspace on Jenkins

This commit is contained in:
2026-08-10 11:18:44 +09:00
parent 219f0e22a8
commit e9467b15f9
5 changed files with 182 additions and 1 deletions

48
Jenkinsfile vendored Normal file
View File

@@ -0,0 +1,48 @@
pipeline {
agent { label 'agent-harness' }
options {
disableConcurrentBuilds()
skipDefaultCheckout(true)
timestamps()
}
triggers {
cron('TZ=Asia/Seoul\nH 8 * * 1-5')
}
stages {
stage('Verify Workspace') {
steps {
powershell '''
$ErrorActionPreference = 'Stop'
if ([string]::IsNullOrWhiteSpace($env:KRI_DEV_ROOT)) {
throw 'KRI_DEV_ROOT must point to the existing KRI multi-repository workspace root.'
}
$harnessRoot = Join-Path $env:KRI_DEV_ROOT '_________AgentHarnessBase'
$verificationScript = Join-Path $harnessRoot 'scripts\verify-workspace.ps1'
if (-not (Test-Path -LiteralPath $verificationScript -PathType Leaf)) {
throw "Workspace verification script not found: $verificationScript"
}
& $verificationScript -WorkspaceRoot $env:KRI_DEV_ROOT
if ($LASTEXITCODE -ne 0) {
exit $LASTEXITCODE
}
'''
}
}
}
post {
success {
echo 'All registered Agent Harness documents are current.'
}
failure {
echo 'Agent Harness drift or an invalid workspace registration was detected.'
}
}
}