Skip to content

Conditionally run child pipelines based on MR title [gemnasium only]

What does this MR do?

  1. Changes the parent pipeline from a Branch Pipeline to a Merge request pipeline:

    - - template: 'Workflows/Branch-Pipelines.gitlab-ci.yml'
    + - template: 'Workflows/MergeRequest-Pipelines.gitlab-ci.yml'
  2. Adds a rule to the child-pipeline trigger jobs to conditionally run the child pipeline if the MR title matches <anything> [<analyzer name> only], for example:

    MR Title Child pipelines executed
    Conditionally run child pipelines based on MR title gemnasium
    gemnasium-maven
    gemnasium-python
    Conditionally run child pipelines based on MR title [gemnasium only] gemnasium
    Conditionally run child pipelines based on MR title [gemnasium-maven only] gemnasium-maven
    Conditionally run child pipelines based on MR title [gemnasium-python only] gemnasium-python
    Conditionally run child pipelines based on MR title [anything only] no child pipelines are executed, the pre-build and `test` stages are executed
  3. Changes the following child branch pipelines:

    to Merge request child pipelines.

Note: By switching to merge request pipelines we now have the ability to click the Run pipeline button from the pipelines screen in the merge request:

What are the relevant issue numbers?

Conditionally run gemnasium child pipelines bas... (gitlab-org/gitlab#365313 - closed)

Does this MR meet the acceptance criteria?

Testing

See the table in the What does this MR do? section.

Edited by Adam Cohen

Merge request reports

Loading