Vendored
+7
-20
@@ -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') {
|
||||
|
||||
Reference in New Issue
Block a user