-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Set --service-account-issuer for k8s 1.20+ #10284
Set --service-account-issuer for k8s 1.20+ #10284
Conversation
7676443
to
9607b99
Compare
pkg/model/iam/subject.go
Outdated
} | ||
|
||
return "", fmt.Errorf("ServiceAcccountIssuer not (currently) supported without PublicJWKS") | ||
return "https://api." + clusterName, nil |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Somewhat unrelated to what this PR is trying to fix, if the admin has set spec.kubeAPIServer.serviceAccountIssuer
explicitly, this should probably return that value instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree we should respect the API field but that could be done in a separate PR.
This function no longer needs to return an error
Service account issuer discovery was promoted to beta in 1.20 so this feature should be enabled by default. I don't think we need to do anything in particular around that feature. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this looks good to me but I'd like Justin's opinion on potential impact
/cc @justinsb
pkg/model/iam/subject.go
Outdated
} | ||
|
||
return "", fmt.Errorf("ServiceAcccountIssuer not (currently) supported without PublicJWKS") | ||
return "https://api." + clusterName, nil |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree we should respect the API field but that could be done in a separate PR.
This function no longer needs to return an error
This looks good. One thing we'll have to verify is that upgrading works! /approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: justinsb The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Kubernetes 1.20+ requires the
--service-account-issuer
flag be passed to kube-apiserverFixes #10279
/cc @justinsb