Skip to content

add --wait-for-airgap to release promote#721

Merged
bennyyang11 merged 5 commits into
mainfrom
bennyyang/sc-136443/cli-wait-for-airgap-builds
May 13, 2026
Merged

add --wait-for-airgap to release promote#721
bennyyang11 merged 5 commits into
mainfrom
bennyyang/sc-136443/cli-wait-for-airgap-builds

Conversation

@bennyyang11
Copy link
Copy Markdown
Member

Adds --wait-for-airgap to release promote and release create --promote for KOTS apps. When set, the CLI polls the new airgap status endpoint and exits non-zero if any channel-release ends in a terminal failure (failed, failed_with_metadata, cancelled, warn). Default off, configurable timeout via --wait-for-airgap-timeout (default 30m).

Also surfaces airgap data in two read commands: an AIRGAP BUNDLES section on release inspect and AIRGAP_STATUS / AIRGAP_ERROR columns on channel releases .

Closes the "misleading success" gap where promote returns 200 but the asynchronous airgap build silently fails.

Comment thread cli/cmd/release_promote.go
Comment thread cli/cmd/release_promote.go
Comment thread cli/cmd/release_promote.go
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 990ee80. Configure here.

Comment thread cli/cmd/release_promote.go
Comment thread cli/cmd/release_promote.go Outdated
Comment on lines +118 to +126
// The vandoor API always returns airgapBuilds[] for promoted channels (metadata
// generation runs for every channel-release). This branch fires when talking to
// an older server that did not populate the field, or if the response object is
// nil for any reason — both must short-circuit before the range below to avoid
// a nil-pointer dereference.
if promoteResp == nil || len(promoteResp.AirgapBuilds) == 0 {
log.ActionWithoutSpinner("No airgap build status reported by the API (older server, or no channels were promoted)")
return nil
}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would remove the things talking about an "older server"

@bennyyang11 bennyyang11 merged commit 36a5cff into main May 13, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants