updated security
Scrap-Web/pipeline/head This commit looks good

This commit is contained in:
Kay-H7
2026-11-13 17:50:59 -05:00
parent 8979d92c00
commit c864ddd0d2
3 changed files with 72 additions and 20 deletions
Vendored
+7 -20
View File
@@ -67,17 +67,11 @@ pipeline {
}
}
// 6.4.5 (kholmes): dependency + secret checks on the source.
// 6.4.5: dependency and secret checks on the source. Fails closed:
// a missing script, a scanner error, or a finding stops the run.
stage('Security scan: source') {
steps {
sh '''
if [ -x security/scan.sh ]; then
security/scan.sh source
else
echo "security/scan.sh not added yet (6.4.5)"
fi
'''
}
steps { sh 'bash security/scan.sh source' }
post { always { archiveArtifacts artifacts: 'security-reports/**', allowEmptyArchive: true } }
}
stage('Build image') {
@@ -88,17 +82,10 @@ pipeline {
}
}
// 6.4.5 (kholmes): image vulnerability scan before publishing.
// 6.4.5: image vulnerability scan before publishing. Fails closed.
stage('Security scan: image') {
steps {
sh '''
if [ -x security/scan.sh ]; then
security/scan.sh image "$IMAGE_TAG"
else
echo "security/scan.sh not added yet (6.4.5)"
fi
'''
}
steps { sh 'bash security/scan.sh image "$IMAGE_TAG"' }
post { always { archiveArtifacts artifacts: 'security-reports/**', allowEmptyArchive: true } }
}
stage('Publish') {