qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] gitlab-ci: Allow adding manual jobs on cirrus-ci


From: Thomas Huth
Subject: Re: [PATCH] gitlab-ci: Allow adding manual jobs on cirrus-ci
Date: Tue, 17 May 2022 12:10:30 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.0

On 14/03/2022 15.31, Philippe Mathieu-Daudé wrote:
From: Philippe Mathieu-Daudé <f4bug@amsat.org>

By default, all Cirrus-CI jobs are added as 'on_success' (the
default value). Add a ${MANUAL_JOB} variable (default to 0)
to be able to add manual jobs.

Suggested-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
  .gitlab-ci.d/cirrus.yml       | 2 ++
  .gitlab-ci.d/cirrus/build.yml | 1 +
  2 files changed, 3 insertions(+)

diff --git a/.gitlab-ci.d/cirrus.yml b/.gitlab-ci.d/cirrus.yml
index b96b22e269..9e640019dd 100644
--- a/.gitlab-ci.d/cirrus.yml
+++ b/.gitlab-ci.d/cirrus.yml
@@ -44,6 +44,8 @@
      # Allow on 'staging' branch and 'stable-X.Y-staging' branches only
      - if: '$CI_PROJECT_NAMESPACE == "qemu-project" && $CI_COMMIT_BRANCH !~ 
/staging/'
        when: never
+    - if: '$CIRRUS_GITHUB_REPO && $CIRRUS_API_TOKEN && $MANUAL_JOB == "1"'
+      when: manual
      - if: "$CIRRUS_GITHUB_REPO && $CIRRUS_API_TOKEN"
x64-freebsd-12-build:
diff --git a/.gitlab-ci.d/cirrus/build.yml b/.gitlab-ci.d/cirrus/build.yml
index c555f5d36e..c58dc86855 100644
--- a/.gitlab-ci.d/cirrus/build.yml
+++ b/.gitlab-ci.d/cirrus/build.yml
@@ -14,6 +14,7 @@ env:
    MAKE: "@MAKE@"
    CONFIGURE_ARGS: "@CONFIGURE_ARGS@"
    TEST_TARGETS: "@TEST_TARGETS@"
+  MANUAL_JOB: 0
build_task:
    install_script:

 Hi Philippe!

Sorry for the late reply ... I think this might collide with Daniel's patch that turns most jobs to manual mode (https://lore.kernel.org/all/20210812180403.4129067-3-berrange@redhat.com/) which he is hopefully going to respin soon ... but anyway, if you add a variable like this, there should be an update to docs/devel/ci-jobs.rst.inc to describe the new variable, otherwise you might be the only one who's using it.

 Thomas




reply via email to

[Prev in Thread] Current Thread [Next in Thread]