Skip to content

fix(ci): restore missing build_type check in release pipeline - #504

Merged
erikcurrin-elastic merged 1 commit into
mainfrom
fix/release-pipeline-snapshot-check
Sep 18, 2026
Merged

erikcurrin-elastic merged 1 commit into
mainfrom
fix/release-pipeline-snapshot-check

Conversation

@erikcurrin-elastic

Copy link
Copy Markdown
Contributor

Summary

Fixes a regression introduced in #503 where the outer if [[ "$BUILD_TYPE" == "release" ]] guard was accidentally dropped from the "Resolve build type" step.

Bug: The branch pattern check (^[0-9]+\.[0-9]+$) ran unconditionally, so any Snapshot build triggered from main would fail immediately with a misleading error:

ERROR: Release builds require an N.N branch (for example, 1.0)

Fix: Restore the missing if [[ "$BUILD_TYPE" == "release" ]]; then wrapper so the branch guard only runs for Release builds.

Test plan

  • Trigger the release pipeline from main with default Snapshot settings → confirm SNAPSHOT image published (was broken before this fix)
  • Trigger the release pipeline from main and choose "Release" → confirm it is rejected
  • Trigger the release pipeline from 1.0 with "Release" → confirm release image published

🤖 Generated with Claude Code

The outer `if [[ "$BUILD_TYPE" == "release" ]]` guard was accidentally
dropped in #503, leaving the branch pattern check unconditional. Any
Snapshot build triggered from main would hit the N.N branch guard and
exit 1 with a misleading "Release builds require an N.N branch" error.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@erikcurrin-elastic
erikcurrin-elastic requested a review from a team as a code owner September 18, 2026 18:03
@erikcurrin-elastic
erikcurrin-elastic merged commit 743c95b into main Sep 18, 2026
2 checks passed
@erikcurrin-elastic
erikcurrin-elastic deleted the fix/release-pipeline-snapshot-check branch September 18, 2026 19:11
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown

💚 Backport PR(s) successfully created

Status Branch Result
✅ 1.0 #511

This backport PR will be merged automatically after passing CI.

Jan-Kazlouski-elastic pushed a commit that referenced this pull request Oct 5, 2026
…504) (#511)

Backports the following commits to 1.0:
 - fix(ci): restore missing build_type check in release pipeline (#504)

Co-authored-by: Erik Currin <erik.currin@elastic.co>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants