[Infrastructure] CI/CD pipelines improvements
The goal is to adjust the pipelines to be triggered only from concrete events (e.g. MR) avoiding building images when it is not necessary.
Some suggestions from @davidremon and @sebastienheurtematte:
This can be achieve in many ways, these are the possibilities that comes to my mind quickly:
- Use a more fine grained "rules" condition in build job, e.g: define only builds on schedule pipeline. on weekly basis for instance: $CI_PIPELINE_SOURCE == "schedule",
- Or build only when pushing a MR to a protected branch
- Dedicate a specific repository for building docker images.
Current rules are defined here and can be adapted by projects: https://gitlab.eclipse.org/eclipsefdn/it/releng/gitlab-runner-service/gitlab-ci-templates/-/blob/main/pipeline-autodevops.gitlab-ci.yml?ref_type=heads#L53 --
Edited by Javier Belenguer Faguás