[all PATCH v2] gitlab: add CI job for validating DCO signoff

Daniel P. Berrangé posted 1 patch 4 years, 7 months ago
Failed in applying to current master (apply log)
.gitlab-ci.yml | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
create mode 100644 .gitlab-ci.yml
[all PATCH v2] gitlab: add CI job for validating DCO signoff
Posted by Daniel P. Berrangé 4 years, 7 months ago
This job uses the shared "check-dco" image to validate that all
commits on a branch in a developer's repo fork have a suitable
Signed-off-by statement present.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
---

This patch was against the Perl repo, but if this is approved then
I'll also apply it to *all* the other repos which currently lack a
DCO check, without reposting further patches for each repo.

For libvirt.git I'll send a patch to update its existing DCO job.

Changed in v2:

 - Exclude based on project namespace, not branch names

.gitlab-ci.yml | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)
 create mode 100644 .gitlab-ci.yml

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000..50dae92
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,16 @@
+
+stages:
+  - prebuild
+
+# Check that all commits are signed-off for the DCO.
+# Skip on "libvirt" namespace, since we only need to run
+# this test on developer's personal forks from which
+# merge requests are submitted
+check-dco:
+  stage: prebuild
+  image: registry.gitlab.com/libvirt/libvirt-ci/check-dco:master
+  script:
+    - /check-dco
+  except:
+    variables:
+      - $CI_PROJECT_NAMESPACE == 'libvirt'
-- 
2.25.2

Re: [all PATCH v2] gitlab: add CI job for validating DCO signoff
Posted by Andrea Bolognani 4 years, 7 months ago
On Wed, 2020-04-22 at 18:31 +0100, Daniel P. Berrangé wrote:
> +# Check that all commits are signed-off for the DCO.
> +# Skip on "libvirt" namespace, since we only need to run
> +# this test on developer's personal forks from which
> +# merge requests are submitted
> +check-dco:
> +  stage: prebuild
> +  image: registry.gitlab.com/libvirt/libvirt-ci/check-dco:master
> +  script:
> +    - /check-dco
> +  except:
> +    variables:
> +      - $CI_PROJECT_NAMESPACE == 'libvirt'

I still don't understand why we can't keep things simple and just run
the check everywhere, but I think I'm done arguing :)

Reviewed-by: Andrea Bolognani <abologna@redhat.com>

-- 
Andrea Bolognani / Red Hat / Virtualization