-
Improvement
-
Resolution: Unresolved
-
Major
-
Jenkins 2.426.2
Warnings NG plugin 10.5.3
While executing the recordIssues step with a defined quality gate to set stage and build results to "failed", it just sets status, but it doesn't prevent execution of the rest of the pipeline and I'm not sure if this is the expected behavior.
In my case, I'm executing whole security checks before uploading built artifacts, and I would like to prevent this step execution for artifacts that do not meet specific security requirements (defined via quality gate). But even if the "Security scans" stage and even the whole build are set to "failed" due to the quality gate status, the next stages, including "Upload artifacts", are still executed.
pipeline { agent {...} stages { stage("Earlier stages") {...} stage("Security scans") { makeSecurityScans() recordIssues tools: [...], qualityGates: [[threshold: 1, type: 'TOTAL_ERROR', unstable: false]] } stage("Upload artifacts") { uploadArtifacts() } } }
- duplicates
-
JENKINS-72059 quality gate setting to only set stage to unstable except of whole build
- Resolved