Fix a pipeline an org rule blocks
When you save a project's pipeline and its step into production breaks an org rule, a rule set to Block refuses the save and one set to Warn saves with a warning (Pipeline rules).
Either way the fix is the same: change the step into production until it meets the rule.
Who can do this: anyone who may edit the project. Only an Org Owner or Org Admin can change the rule itself.
Plan: a project's custom pipeline, under Settings › CI Pipeline, shows only where the organization's plan includes Custom pipelines.
Fix the step
-
In the sidebar, select Directory, then the Projects tab, and select the project's name. In Settings, select CI Pipeline.
-
Find the card with the message. It starts with Org rule: and ends with what to change, for example Org rule: the step into Production needs at least 2 approvals. Set Approvals to 2 or more. Your unsaved changes are still on the page.
-
Under Steps, select the step into that stage, such as Release from Dev to Production. Its settings open.
-
Change the setting the message names:
The message says Change needs at least N approvals Under Approvals, pick N or more in Needed. must not run by itself Under Who, set Runs to By hand. Runs is on the step's panel; the steps table shows it as How it runs. only maintainers and above may press Under Who, open Can press and untick Developer (and Viewer, if it shows). Name a person instead if they need to press it. -
Select Save. The message clears from the card once the step meets every rule. If another rule is still broken, its message shows next; repeat steps 3 to 5.
-
To drop your changes instead, select Discard. The pipeline goes back to its last save.
A release already running keeps its old settings; the fixed step applies from the next run.
When you can't change the step
- A field is locked by a template. On a project linked to an org template, a locked field reads only. Ask whoever keeps the template to fix it there, or unlink the project (Link a project to a template).
- The rule doesn't fit this project. A block applies to everyone, Org Owners included. Ask an Org Owner or Org Admin to change the rule's mode (Set your org's pipeline rules).
Related
- Every stage and step setting: Set up a project's pipeline.
- Approval count, approvers and timeouts: Require approval before a step moves on.
- What each rule and mode means: Pipeline rules.