1775 run partial pipelines
Description
https://repo1.dso.mil/ironbank-tools/infra/ironbank-bootstrap/-/issues/1775
This MR adds the ability to stop the pipeline after the build job when:
- SKIP_SCAN variable is True
- AND the commit branch is NOT development or master
To implement this I added rules to determine what stages should be included with each pipeline run. To run the partial pipeline the user needs to create a project level variable called SKIP_SCAN and set it to true. With this set, when they run a pipeline on a branch that is not "master" or "development", any jobs after the build stage will not be included.
If SKIP_SCAN is any other value besides true or if it does not exist, then the pipeline will run with all the jobs as usual.
Risk
Rollback Plan
Testing
- An example of the skipped jobs in action: https://code-ib-mario.staging.dso.mil/dsop/rflynn/ubi8/-/pipelines/27342
- The same repo configuration but running on the master branch https://code-ib-mario.staging.dso.mil/dsop/rflynn/ubi8/-/pipelines/27337
More details of each case being tested with the UBI8 and openjdk11 repos can be found on the ticket: (https://repo1.dso.mil/ironbank-tools/infra/ironbank-bootstrap/-/issues/1775#note_1829880) and (https://repo1.dso.mil/ironbank-tools/infra/ironbank-bootstrap/-/issues/1775#note_1830012)