-
Notifications
You must be signed in to change notification settings - Fork 40.6k
Duplicate v1beta1 AuthenticationConfiguration to v1 #131752
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
base: master
Are you sure you want to change the base?
Conversation
/assign enj liggitt |
This PR may require API review. If so, when the changes are ready, complete the pre-review checklist and request an API review. Status of requested reviews is tracked in the API Review project. |
Signed-off-by: Anish Ramasekar <anish.ramasekar@gmail.com>
Signed-off-by: Anish Ramasekar <anish.ramasekar@gmail.com>
33995d7
to
2aa6627
Compare
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: aramase 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 |
@@ -152,7 +152,7 @@ func runTests(t *testing.T, useAuthenticationConfig bool) { | ||
|
||
if useAuthenticationConfig { | ||
authenticationConfig := fmt.Sprintf(` | ||
apiVersion: apiserver.config.k8s.io/v1beta1 |
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.
Do we want to keep some testing for older versions too? looks like when we added v1beta1, we still had v1alpha1 as well? (eye-balling the rest of the changes in this file)
|
||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object | ||
|
||
// AuthenticationConfiguration provides versioned configuration for authentication. |
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.
the order of the structs in staging/src/k8s.io/apiserver/pkg/apis/apiserver/v1beta1/types.go and this file ( staging/src/k8s.io/apiserver/pkg/apis/apiserver/types.go ) is now different. so it gets harder to compare over time. Do we want to keep the order the same so a diff would be clearer?
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 can confirm that is is a cut-n-paste for v1beta1 for sure :)
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object | ||
|
||
// AuthenticationConfiguration provides versioned configuration for authentication. | ||
type AuthenticationConfiguration struct { |
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.
the code in v1beta1 was added in:
- https://github.com/kubernetes/kubernetes/pull/123696/files
3 PRs that touched the code afterwards: - 916c786
- 121607e
- 5e6a493
I do not see any version specific manual defaults or conversions. Will take one more pass in a bit
// Valid types for AudienceMatchPolicyType | ||
const ( | ||
// MatchAny means the "aud" claim in the presented JWT must match at least one of the entries in the "audiences" field. | ||
AudienceMatchPolicyMatchAny AudienceMatchPolicyType = "MatchAny" |
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.
Looking at uses of this const in various files - https://cs.k8s.io/?q=AudienceMatchPolicyMatchAny&i=nope&literal=nope&files=&excludeFiles=&repos=kubernetes/kubernetes
is this for end user use only? (since we don't use it internally)
What type of PR is this?
/kind feature
/kind api-change
What this PR does / why we need it:
Adds apiserver.config.k8s.io/v1 AuthenticationConfiguration types
part of kubernetes/enhancements#3331
Special notes for your reviewer:
Does this PR introduce a user-facing change?
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:
/sig auth
/triage accepted
/priority important-soon