From 0c8c6fbeaceee2c3338ccff9af369deadad43969 Mon Sep 17 00:00:00 2001 From: Killian Delarue Date: Thu, 30 Oct 2025 15:22:01 +0100 Subject: [PATCH] CI, Releases: New job [dispatch-call] in release pipeline --- .../octez_major_release_tag_test.yml | 25 ++++++++++++++++ .../octez_minor_release_tag_test.yml | 25 ++++++++++++++++ .gitlab/ci/pipelines/octez_release_tag.yml | 25 ++++++++++++++++ ci/lib_tezos_ci_jobs/release_tag.ml | 29 +++++++++++++++++-- 4 files changed, 101 insertions(+), 3 deletions(-) diff --git a/.gitlab/ci/pipelines/octez_major_release_tag_test.yml b/.gitlab/ci/pipelines/octez_major_release_tag_test.yml index bc78a773ebfe..abe5e2ff4602 100644 --- a/.gitlab/ci/pipelines/octez_major_release_tag_test.yml +++ b/.gitlab/ci/pipelines/octez_major_release_tag_test.yml @@ -1561,3 +1561,28 @@ publish:release-page: - ./index.md - index.html retry: 0 + +dispatch-call: + image: ${ci_image_name}/prebuild:${ci_image_tag} + stage: publish + tags: + - gcp + needs: + - oc.docker:ci:amd64 + - publish:release-page + - gitlab:release + dependencies: + - oc.docker:ci:amd64 + timeout: 60 minutes + interruptible: false + before_script: + - SCRIPT_STEP_BEGIN=$(date +%s) + - . ./scripts/ci/datadog_send_job_info.sh + - . ./scripts/ci/datadog_send_job_cache_info.sh 'before' + script: + - 'curl -L -X POST -H "Accept: application/vnd.github+json" -H "Authorization: Bearer + ${TEZCAPITAL_GITHUB_TOKEN}" -H "X-GitHub-Api-Version: 2022-11-28" https://api.github.com/repos/tez-capital/tezos-macos-pipeline/actions/workflows/macos.yml/dispatches + -d ''{"ref":"main","inputs":{"version": "${CI_COMMIT_TAG}"}}''' + - . ./scripts/ci/datadog_send_job_script_step_time.sh || true + after_script: + - . ./scripts/ci/datadog_send_job_cache_info.sh 'after' diff --git a/.gitlab/ci/pipelines/octez_minor_release_tag_test.yml b/.gitlab/ci/pipelines/octez_minor_release_tag_test.yml index 09fdb2063324..75eed5c8309c 100644 --- a/.gitlab/ci/pipelines/octez_minor_release_tag_test.yml +++ b/.gitlab/ci/pipelines/octez_minor_release_tag_test.yml @@ -1087,3 +1087,28 @@ publish:release-page: - ./index.md - index.html retry: 0 + +dispatch-call: + image: ${ci_image_name}/prebuild:${ci_image_tag} + stage: publish + tags: + - gcp + needs: + - oc.docker:ci:amd64 + - publish:release-page + - gitlab:release + dependencies: + - oc.docker:ci:amd64 + timeout: 60 minutes + interruptible: false + before_script: + - SCRIPT_STEP_BEGIN=$(date +%s) + - . ./scripts/ci/datadog_send_job_info.sh + - . ./scripts/ci/datadog_send_job_cache_info.sh 'before' + script: + - 'curl -L -X POST -H "Accept: application/vnd.github+json" -H "Authorization: Bearer + ${TEZCAPITAL_GITHUB_TOKEN}" -H "X-GitHub-Api-Version: 2022-11-28" https://api.github.com/repos/tez-capital/tezos-macos-pipeline/actions/workflows/macos.yml/dispatches + -d ''{"ref":"main","inputs":{"version": "${CI_COMMIT_TAG}"}}''' + - . ./scripts/ci/datadog_send_job_script_step_time.sh || true + after_script: + - . ./scripts/ci/datadog_send_job_cache_info.sh 'after' diff --git a/.gitlab/ci/pipelines/octez_release_tag.yml b/.gitlab/ci/pipelines/octez_release_tag.yml index c982b9dc798e..6bf7ac5e338b 100644 --- a/.gitlab/ci/pipelines/octez_release_tag.yml +++ b/.gitlab/ci/pipelines/octez_release_tag.yml @@ -1061,3 +1061,28 @@ publish:release-page: - ./index.md - index.html retry: 0 + +dispatch-call: + image: ${ci_image_name}/prebuild:${ci_image_tag} + stage: publish + tags: + - gcp + needs: + - oc.docker:ci:amd64 + - publish:release-page + - gitlab:release + dependencies: + - oc.docker:ci:amd64 + timeout: 60 minutes + interruptible: false + before_script: + - SCRIPT_STEP_BEGIN=$(date +%s) + - . ./scripts/ci/datadog_send_job_info.sh + - . ./scripts/ci/datadog_send_job_cache_info.sh 'before' + script: + - 'curl -L -X POST -H "Accept: application/vnd.github+json" -H "Authorization: Bearer + ${TEZCAPITAL_GITHUB_TOKEN}" -H "X-GitHub-Api-Version: 2022-11-28" https://api.github.com/repos/tez-capital/tezos-macos-pipeline/actions/workflows/macos.yml/dispatches + -d ''{"ref":"main","inputs":{"version": "${CI_COMMIT_TAG}"}}''' + - . ./scripts/ci/datadog_send_job_script_step_time.sh || true + after_script: + - . ./scripts/ci/datadog_send_job_cache_info.sh 'after' diff --git a/ci/lib_tezos_ci_jobs/release_tag.ml b/ci/lib_tezos_ci_jobs/release_tag.ml index ed3a45f2c5d7..933dd4264be6 100644 --- a/ci/lib_tezos_ci_jobs/release_tag.ml +++ b/ci/lib_tezos_ci_jobs/release_tag.ml @@ -298,6 +298,29 @@ let octez_jobs ?(test = false) ?(major = true) release_tag_pipeline_type = ~dependencies:(Dependent [Job job_docker_merge]) () in + let job_dispatch_call = + job + ~__POS__ + ~image:Images.CI.prebuild + ~stage:Stages.publish + ~description: + "A job release that triggers pipelines from other repositories after a \ + release.\n\ + For now, it triggers the release pipeline from \ + tez-capital/tezos-macos-pipeline" + ~interruptible:false + ~name:"dispatch-call" + ~dependencies: + (Dependent [Job job_release_page; Job job_gitlab_release_or_publish]) + [ + "curl -L -X POST -H \"Accept: application/vnd.github+json\" -H \ + \"Authorization: Bearer ${TEZCAPITAL_GITHUB_TOKEN}\" -H \ + \"X-GitHub-Api-Version: 2022-11-28\" \ + https://api.github.com/repos/tez-capital/tezos-macos-pipeline/actions/workflows/macos.yml/dispatches \ + -d '{\"ref\":\"main\",\"inputs\":{\"version\": \ + \"${CI_COMMIT_TAG}\"}}'"; + ] + in let job_trigger_monitoring = trigger_job ~__POS__ @@ -334,9 +357,8 @@ let octez_jobs ?(test = false) ?(major = true) release_tag_pipeline_type = Schedule_test") @ match (test, release_tag_pipeline_type) with - (* for the moment the apt repository are not official, so we do not add to the release - pipeline . *) - | false, Release_tag -> [job_opam_release (); job_release_page] + | false, Release_tag -> + [job_opam_release (); job_release_page; job_dispatch_call] | true, Release_tag -> [ (* This job normally runs in the {!Octez_latest_release} pipeline @@ -347,6 +369,7 @@ let octez_jobs ?(test = false) ?(major = true) release_tag_pipeline_type = job_promote_to_latest_test; job_opam_release ~dry_run:true (); job_release_page; + job_dispatch_call; ] | _ -> [] -- GitLab