fix(template): register Organization and Team as shared resource consumers#33
Open
cshiels-ie wants to merge 1 commit into
Open
fix(template): register Organization and Team as shared resource consumers#33cshiels-ie wants to merge 1 commit into
cshiels-ie wants to merge 1 commit into
Conversation
…umers Services built from this framework are consumers of org/team data from the gateway, not providers. is_provider=True caused them to register as metrics.organization/team instead of the correct shared.organization/team, breaking gateway JWT auth for role assignments. Discovered via ansible/metrics-service#320. Assisted-by: Claude Code (claude-sonnet-4-6) Co-Authored-By: Claude Sonnet 4.6 (1M context) <[email protected]>
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
OrganizationandTeamintemplates/core/resource_api.py.jinjafromis_provider=True, serializer=Nonetois_provider=FalsewithOrganizationType/TeamTypeserializers.Problem
Services generated by this framework are consumers of org/team data from the AAP gateway, not providers. With
is_provider=True, DAB registers them as<service>.organization/<service>.teaminstead ofshared.organization/shared.team. This mismatch breaks gateway JWT auth for role assignments — the gateway exposes the shared variants, so claims validation fails with HTTP 403 for users who have role assignments.Discovered via the same fix applied to metrics-service in ansible/metrics-service#320.
AI Assistance
This change was developed with assistance from Claude Code (Claude Sonnet 4.6).
All generated code was reviewed, tested, and validated before merging.