From: Michael Hofmann <[email protected]>

gitlab-ci: restore bot pipeline behavior

For cki-ark-bot, the triggered MR pipelines are supposed to only build
the SRPM in the various build roots.

This got broken a while ago, most likely when kernel-ark was switched to
merge-result pipelines.

The previous implementation checked the git commit author, which doesn't
work for merged-result pipelines as the merge commit is generated by
GitLab. Switch that to check the name of the user who started the MR
pipeline, which should work in all cases.

Fixes https://gitlab.com/cki-project/kernel-ark/-/issues/163

Signed-off-by: Michael Hofmann <[email protected]>

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index blahblah..blahblah 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -74,11 +74,11 @@ workflow:
     when: manual
     allow_failure: true
   manual-for-bot: &manual-for-bot
-    if: $CI_COMMIT_AUTHOR =~ /<[email protected]>/
+    if: $GITLAB_USER_LOGIN == "cki-ark-bot"
     when: manual
     allow_failure: true
   srpm-for-bot: &srpm-for-bot
-    if: $CI_COMMIT_AUTHOR =~ /<[email protected]>/
+    if: $GITLAB_USER_LOGIN == "cki-ark-bot"
     when: on_success
     variables:
       skip_build: 'true'

--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/3292

-- 
_______________________________________________
kernel mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/[email protected]
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to