GitLab: How to skip or allow pipeline step after rebasing online
Asked Answered
C

2

6

While reviewing a merge request on gitlab.com, there are times when I have to rebase before completing the merge.

enter image description here

After pressing “Rebase” on gitlab, I have a specific pipeline step fails because it can’t verify the user’s gpg: signature.

How can I skip (or allow) this step when I rebase changes online? Is there a GiLab user id for this online process?

Crista answered 1/9, 2020 at 7:29 Comment(0)
L
5

From Gitlab UI you can not.

Actually, from GitLab 15.3 (August 2022), you can:

Rebase a merge request from the UI without triggering a pipeline

In large and busy monorepos with semi-linear branching, you might need to rebase your merge requests frequently. To save resources, you might not want to run a pipeline each time you rebase. You could skip the pipeline while rebasing with the API, or by using Git push options or [ci skip] in a commit message, but not when rebasing from the UI in a merge request.

Now we have an option to skip the pipeline when rebasing from the UI, so you have better control over when a pipeline runs for your merge requests. Thanks to Kev for the contribution!

See Documentation and Issue.

To rebase a merge request’s branch without triggering a CI/CD pipeline, select Rebase without pipeline from the merge request reports section.
This option is available when fast-forward merge is not possible but a conflict-free rebase is possible.

Rebasing without a CI/CD pipeline saves resources in projects with a semi-linear workflow that requires frequent rebase

Lepsy answered 1/9, 2022 at 22:27 Comment(0)
A
2

This rebase option appeared here because your master branch is ahead of the merge request branch with no conflict. So to avoid this I would suggest rebase locally it means all the chnages and commits from master will get updated with your merge request branch and then push it you will not see this rebase option on gitlab anymore.

to rebase use

git rebase origin/master
Anathematize answered 2/9, 2020 at 7:49 Comment(1)
Fair enough. Thanks.Crista

© 2022 - 2024 — McMap. All rights reserved.