Skip to content

Attach jobs to pipelines using PIPELINE_TYPE

Balasankar 'Balu' C requested to merge 6765-switch-to-rules-com into master
Attach jobs to pipelines using PIPELINE_TYPE

Consolidates the complex rules governing Omnibus GitLab pipelines into a
single place by attaching jobs based on the type of pipeline. The
PIPELINE_TYPE variable is calculated based on elements of the build
environment such as project path, variables, and etc. Each job
definition lists the PIPELINE_TYPEs it should join.

This iteration does not touch any build or release jobs and only impacts
jobs running on GitLab.com.

Related https://gitlab.com/gitlab-org/omnibus-gitlab/-/issues/6765

Signed-off-by: Balasankar "Balu" C <balasankar@gitlab.com>

What does this MR do?

Instead of maintaining complex rules across the CI configuration, consolidate them to a single place by detecting what type of pipeline we are running, and then selecting the jobs appropriate to each pipeline type. We will calculate a variable PIPELINE_TYPE based on the build environment (project path, variables, etc.) and then in each job list out the different pipeline types of which the job should be a part of.

This iteration does not touch any build/release jobs. Only the jobs running in GitLab.com.

Related issues

Related to #6765 (closed)

Closes: #7188 (closed)

Checklist

See Definition of done.

For anything in this list which will not be completed, please provide a reason in the MR discussion

Required

  • Merge Request Title, and Description are up to date, accurate, and descriptive
  • MR targeting the appropriate branch
  • MR has a green pipeline on GitLab.com
  • Pipeline is green on dev.gitlab.org if the change is touching anything besides documentation or internal cookbooks
  • trigger-package has a green pipeline running against latest commit

Expected (please provide an explanation if not completing)

  • Test plan indicating conditions for success has been posted and passes
  • Documentation created/updated
  • Tests added
  • Integration tests added to GitLab QA
  • Equivalent MR/issue for the GitLab Chart opened
Edited by Balasankar 'Balu' C

Merge request reports