Reputation: 437
Present we kept multiple pipelines in separate yml files and all of them are included in the mail ci yml file. using include statements.
Is there anyway to make it conditional.
Like I will have pipeline1 and pipeline2 yaml files.
So I can create another pipeline.yml where I can choose among the above two files based on some condition.
Upvotes: 2
Views: 228
Reputation: 720
Gitlab is designed for deterministic pipelines, all other solutions add-on that looks implicit.
Include in .gitlab-ci.yml
link to the web server, which could be a dynamically generated yml file.
include:
- 'https://your-service.com/gitlab-ci-generate'
Unfortunately, It's not possible to use CI variables in link to server. gitlab issue link
You have complete control of the pipeline. Write a simple bash script, which renames your pre-pushed .yml files and executes that pipeline.
Upvotes: 1