Skip to content

Implement changes rules for executing full and docs-only pipelines

Mark Fletcher requested to merge runner-docs-only-changes-rules into main

What does this MR do?

Aims to introduce rules to run docs only jobs or full pipeline based on changes made.

The MR aims to introduce rules to run jobs based on the changes made. The patterns followed are for:

  • code/backstage changes
  • docs changes

For docs only changes only docs related jobs should be added to the pipeline

For code only or code and docs changes a full pipeline should be executed

Why was this MR needed?

Currently a docs only pipeline is invoked based on the source branch name matching a docs related regular expression.

This MR aims to kick off a docs only pipeline if only docs related changes have been made.

What's the best way to test this MR?

Tests

Category Test MR Docs Code Pipeline Matches similar, previous pipeline Comparison source
Docs only canonical MR pipeline 1 !2991 (closed) https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/328067588 https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/326183075
Docs only canonical MR pipeline 2 ... ... ... ... ... https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/322219714
Code only canonical MR pipeline 1 !2992 (closed) https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/328085886 https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/324486646
Code only canonical MR pipeline 2 ... ... ... ... ... https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/321282178
Code and Docs canonical MR pipeline 1 !2996 (closed) https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/328676354 https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/314621548
Code and Docs canonical MR pipeline 2 ... ... ... ... ... https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/314533220
Docs only then code !2997 (closed) Commit 1, Docs only: https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/328679544 Commit 2, Docs and code: https://gitlab.com/gitlab-org/gitlab-runner/-/pipelines/328680053 - -

What are the relevant issue numbers?

Related to #5019 (closed)

Related MRs

This MR is based off of !2938 (merged) source branch

Edited by Mark Fletcher

Merge request reports