[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs
From: |
Philippe Mathieu-Daudé |
Subject: |
[RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs |
Date: |
Mon, 19 Apr 2021 01:34:47 +0200 |
Forks run the same jobs than mainstream, which might be overkill.
Allow them to easily rebase their custom set, while keeping using
the mainstream templates, and ability to pick specific jobs from
the mainstream set.
To switch to your set, simply add your .gitlab-ci.yml as
.gitlab-ci.d/${CI_PROJECT_NAMESPACE}.yml (where CI_PROJECT_NAMESPACE
is your gitlab 'namespace', usually username). This file will be
used instead of the default mainstream set.
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
.gitlab-ci.yml | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 718c8e004be..35fd35075db 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -9,7 +9,12 @@ generate-config:
paths:
- generated-config.yml
script:
- - cp .gitlab-ci.d/qemu-project.yml generated-config.yml
+ - if test -e .gitlab-ci.d/${CI_PROJECT_NAMESPACE}.yml ;
+ then
+ cp .gitlab-ci.d/${CI_PROJECT_NAMESPACE}.yml generated-config.yml ;
+ else
+ cp .gitlab-ci.d/qemu-project.yml generated-config.yml ;
+ fi
generate-pipeline:
stage: test
--
2.26.3
- Re: [PATCH 08/15] gitlab-ci: Extract DCO/style check jobs to checks.yml, (continued)
- [PATCH 09/15] gitlab-ci: Extract build stages to stages.yml, Philippe Mathieu-Daudé, 2021/04/18
- [PATCH 10/15] gitlab-ci: Extract all default build/test jobs to buildtest.yml, Philippe Mathieu-Daudé, 2021/04/18
- [PATCH 11/15] gitlab-ci: Extract core container jobs to container-core.yml, Philippe Mathieu-Daudé, 2021/04/18
- [PATCH 12/15] gitlab-ci: Move current job set to qemu-project.yml, Philippe Mathieu-Daudé, 2021/04/18
- [RFC PATCH 13/15] gitlab-ci: Switch to dynamically generated pipelines, Philippe Mathieu-Daudé, 2021/04/18
- [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs,
Philippe Mathieu-Daudé <=
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Thomas Huth, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Daniel P . Berrangé, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Philippe Mathieu-Daudé, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Erik Skultety, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Thomas Huth, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Daniel P . Berrangé, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Thomas Huth, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Daniel P . Berrangé, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Thomas Huth, 2021/04/19
- Re: [RFC PATCH 14/15] gitlab-ci: Allow forks to use different set of jobs, Daniel P . Berrangé, 2021/04/19