[OS-BUILD PATCHv4 5/6] CI: add ark-latest baseline job to tag cki-gating for successful pipelines

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

 



From: Michael Hofmann <mhofmann@xxxxxxxxxx>

CI: add ark-latest baseline job to tag cki-gating for successful pipelines

For ark-latest branch HEAD pipelines, add an on_success job after all
the child pipelines that will update the cki-gating branch. This branch
is going to get used for gating the automatic update of CKI
builder-rawhide/eln container images.

Part of https://gitlab.com/cki-project/containers/-/issues/46

Signed-off-by: Michael Hofmann <mhofmann@xxxxxxxxxx>

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index blahblah..blahblah 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -55,6 +55,10 @@ workflow:
   only-ark-latest-head: &only-ark-latest-head
     if: $CI_COMMIT_BRANCH != "ark-latest" || $CI_PIPELINE_SOURCE !~ /push|web/
     when: never
+  only-ark-latest-head-mr: &only-ark-latest-head-mr
+    if: ($CI_MERGE_REQUEST_TARGET_BRANCH_NAME != "os-build") &&
+        ($CI_COMMIT_BRANCH != "ark-latest" || $CI_PIPELINE_SOURCE !~ /push|web/)
+    when: never
   only-cki-gating-head: &only-cki-gating-head
     if: $CI_COMMIT_BRANCH != "cki-gating" || $CI_PIPELINE_SOURCE !~ /pipeline/ || $builder_image !~ $JOB_FILTER
     when: never
@@ -485,3 +489,17 @@ pages:
     - *only-os-build-head-mr
     - *manual-on-mr
     - *on-success
+
+tag-cki-gating:
+  image: quay.io/cki/cki-tools:production
+  stage: deploy
+  script:
+    - mkdir --mode 700 --parents ~/.ssh
+    - echo "${GITLAB_KNOWN_HOSTS}" > ~/.ssh/known_hosts
+    - eval $(ssh-agent -s)
+    - ssh-add -q - <<< "${PRIVATE_KEY}"
+    - git push --force git@${CI_SERVER_HOST}:${CI_PROJECT_PATH}.git HEAD:refs/heads/cki-gating
+  rules:
+    - *only-ark-latest-head-mr
+    - *manual-on-mr
+    - *on-success

--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/2742
_______________________________________________
kernel mailing list -- kernel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to kernel-leave@xxxxxxxxxxxxxxxxxxxxxxx
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/kernel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue




[Index of Archives]     [Fedora General Discussion]     [Older Fedora Users Archive]     [Fedora Advisory Board]     [Fedora Security]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Mentors]     [Fedora Package Announce]     [Fedora Package Review]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Coolkey]     [Yum Users]     [Tux]     [Yosemite News]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [USB]     [Asterisk PBX]

  Powered by Linux