Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Fixup SA lookups #3296

Closed
wants to merge 1 commit into from

Conversation

mjudeikis
Copy link
Contributor

@mjudeikis mjudeikis commented Feb 13, 2025

Summary

Service account lookups in claims code is done like this:

serviceAccount, err := v.getter.Cluster(clusterName).GetServiceAccount(namespace, saref.Name)
	if err != nil {
		klog.V(4).Infof("Could not retrieve service account %s/%s: %v", namespace, saref.Name, err)
		return nil, err
	}

this means if we are evaluating service accounts from different shards, we will not be able to do this. This particular client should be the front proxy loopback client, where we gonna route it to the right shard for lookup. Now it's set to roots hard, so it works only when SA lands into the root shard.

Related issue(s)

Fixes #

Release Notes

NONE

Signed-off-by: Mangirdas Judeikis <[email protected]>
On-behalf-of: @SAP [email protected]
@kcp-ci-bot kcp-ci-bot added release-note-none Denotes a PR that doesn't merit a release note. dco-signoff: yes Indicates the PR's author has signed the DCO. labels Feb 13, 2025
@kcp-ci-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please ask for approval from mjudeikis. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kcp-ci-bot kcp-ci-bot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Feb 13, 2025
@mjudeikis mjudeikis marked this pull request as draft February 13, 2025 15:31
@kcp-ci-bot kcp-ci-bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Feb 13, 2025
@mjudeikis mjudeikis closed this Feb 13, 2025
@mjudeikis mjudeikis reopened this Feb 13, 2025
@mjudeikis
Copy link
Contributor Author

/test all

@mjudeikis mjudeikis closed this Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dco-signoff: yes Indicates the PR's author has signed the DCO. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. release-note-none Denotes a PR that doesn't merit a release note. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants