fix(ee): remove broken curl-based Automation Hub token validation#554
Merged
rockygeekz merged 2 commits intoansible:mainfrom Mar 24, 2026
Merged
Conversation
NilashishC
approved these changes
Mar 24, 2026
rockygeekz
approved these changes
Mar 24, 2026
77d08d6 to
a5a877f
Compare
a5a877f to
0cfca70
Compare
The "Validate Automation Hub Token" step sent the offline/refresh token directly as a Bearer token to console.redhat.com, which always fails because the token must first be exchanged via Red Hat SSO. This caused valid tokens to be reported as invalid, while the build itself succeeded (ansible-galaxy handles the SSO exchange via auth_url). Remove the curl validation and let the build be the authoritative check. The "Check if tokens are configured" steps remain so downstream jobs still know whether secrets are present. Made-with: Cursor
Signed-off-by: NilashishC <[email protected]>
0cfca70 to
50fd20d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Bearertoken toconsole.redhat.com/api/automation-hub/, which always fails (401/403) because the token must first be exchanged for an access token via Red Hat SSO (sso.redhat.com/.../openid-connect/token)ansible-galaxyhandles the SSO exchange automatically via theauth_urlinansible.cfgWhy not fix the validation?
Exchanging the offline token via SSO would require hardcoding the Red Hat SSO URL and
client_id, addingjqas a dependency, and would only work forconsole.redhat.com(not on-prem PAH). The build step is the authoritative check — if the token is bad,ansible-galaxy collection installwill fail with a clear error.Reported by
@NilashishC — internal feedback
Test plan
pytest— 196 passed, 3 skippedpre-commit run --all-files— all checks passedMade with Cursor