Fix when include has rules with invalid rule
What does this MR do and why?
Bug description: #341488 (closed)
The include:rules
keyword only supports if conditions.
When you use other conditions, like exists
, the GitLab CI config
file show page returns 500. Also, the created pipeline raises an undefined error.
This MR fixes that error and raises a proper message.
Screenshots or screen recordings
Before
After
How to set up and validate locally
include:
- local: configs/builds.yml
rules:
- exists:
- '$INCLUDE_BUILDS'
test:
stage: test
script: exit 0
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.