-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
deprecate kube-apiserver flag --address
--insecure-port
#4356
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: hzxuzhonghu Assign the PR to them by writing The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these OWNERS Files:
You can indicate your approval by writing |
/assign @justinsb |
This is my first time make a commit to this project, and donnot know how to auto generate openapi. |
So we need to figure out how to deprecate this value instead of removing it. We probably want to validate the value is not included with deprecated k8s versions. validation.go and not remove from api. Mark as deprecated. Open api is not used yet, but there is a make target and you can pr after this is merged. |
@chrislovecnm make sense, I have to look into the code. |
--address
--address
--insecure-port
I am not sure this is right, but I think it should be so. |
/retest |
@hzxuzhonghu: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
// Address is the binding address for the kube api | ||
Address string `json:"address,omitempty" flag:"address"` | ||
// Deprecated: InsecurePort is the port the insecure api runs | ||
InsecurePort int32 `json:"insecurePort,omitempty" flag:"insecure-port" flag-empty:"-1"` |
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.
Does 0 work as the flag-empty value?
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.
First step, I want 0
to disable insecure http schema. So for <v1.10 it continue support 0
.
// Deprecated: InsecurePort is the port the insecure api runs | ||
InsecurePort int32 `json:"insecurePort,omitempty" flag:"insecure-port" flag-empty:"-1"` | ||
// Deprecated: Address is the binding address for the kube api | ||
Address string `json:"address,omitempty" flag:"address" flag-empty:"255.255.255.255"` |
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.
Similarly, can we keep empty-string as the flag-empty value? Just seems more intuitive to have the empty values be the default uninitialized values in go as well. Where that doesn't work is when 0 or "" is a valid flag value...
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.
ok, "" is ok. I just am not familiar with this code, I thought it may has validation.
} else { | ||
c.InsecurePort = 8080 | ||
// We disable the insecure port and address from 1.10 onwards | ||
// https://github.com/kubernetes/kubernetes/issues/58951 |
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 blocker for this is kubernetes/kubernetes#43784 I believe
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.
ok, I c.
Blocked on kubernetes/kubernetes#43784 |
@hzxuzhonghu: PR needs rebase. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Thanks @hzxuzhonghu - I think I might have done some of this in #5234 (sorry, I was cleaning up and forgot your PR). Do we still need this PR, do you think? |
fix #4355
Stop supporting these flags since kubernetes 1.10.