From c382c20ee5a3ff9aa0a219c4acfdd60df088a575 Mon Sep 17 00:00:00 2001 From: Jon Date: Thu, 26 Dec 2024 11:30:21 -0600 Subject: [PATCH] [ci] Update VM cache for each ES snapshot (#205119) Currently we're rebuilding our cache after the ES snapshot on main has been promoted. This makes an assumption that less frequent cache builds will save minutes over the chance of a build failure on main causing snapshots for all other passing branches to be out of date. That assumption hasn't been correct so far, so I'm moving the trigger to all branches. --- .../steps/es_serverless/promote_es_serverless_image.sh | 2 +- .buildkite/scripts/steps/es_snapshots/promote.sh | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.buildkite/scripts/steps/es_serverless/promote_es_serverless_image.sh b/.buildkite/scripts/steps/es_serverless/promote_es_serverless_image.sh index 4598e03b1cdb7..a8885c44cfb74 100755 --- a/.buildkite/scripts/steps/es_serverless/promote_es_serverless_image.sh +++ b/.buildkite/scripts/steps/es_serverless/promote_es_serverless_image.sh @@ -72,7 +72,7 @@ EOT cat << EOF | buildkite-agent pipeline upload steps: - - label: "Builds Kibana VM images for cache update" + - label: "Update cache for ES serverless image" trigger: kibana-vm-images async: true build: diff --git a/.buildkite/scripts/steps/es_snapshots/promote.sh b/.buildkite/scripts/steps/es_snapshots/promote.sh index d09ef2d2420ac..2b85505619a95 100755 --- a/.buildkite/scripts/steps/es_snapshots/promote.sh +++ b/.buildkite/scripts/steps/es_snapshots/promote.sh @@ -16,9 +16,11 @@ ts-node "$(dirname "${0}")/promote_manifest.ts" "$ES_SNAPSHOT_MANIFEST" if [[ "$BUILDKITE_BRANCH" == "main" ]]; then echo "--- Trigger agent packer cache pipeline" ts-node .buildkite/scripts/steps/trigger_pipeline.ts kibana-agent-packer-cache main - cat << EOF | buildkite-agent pipeline upload +fi + +cat << EOF | buildkite-agent pipeline upload steps: - - label: "Builds Kibana VM images for cache update" + - label: "Update cache for ES $BUILDKITE_BRANCH snapshot" trigger: kibana-vm-images async: true build: @@ -26,4 +28,3 @@ steps: IMAGES_CONFIG: "kibana/images.yml" RETRY: "1" EOF -fi