-
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
Add KubeletPreferredAddressTypes #1083
Conversation
Hi @vjm. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with If you have questions or suggestions related to this bot's behavior, please file an issue against the kubernetes/test-infra repository. |
Thanks for your pull request. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please follow instructions at https://github.com/kubernetes/kubernetes/wiki/CLA-FAQ to sign the CLA. Once you've signed, please reply here (e.g. "I signed it!") and we'll verify. Thanks.
If you have questions or suggestions related to this bot's behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
|
1 similar comment
Thanks for your pull request. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please follow instructions at https://github.com/kubernetes/kubernetes/wiki/CLA-FAQ to sign the CLA. Once you've signed, please reply here (e.g. "I signed it!") and we'll verify. Thanks.
If you have questions or suggestions related to this bot's behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
|
@k8s-ci-robot I signed it! |
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.
LGTM once typo is fixed - thanks!
TokenAuthFile string `json:"tokenAuthFile,omitempty" flag:"token-auth-file"` | ||
AllowPrivileged *bool `json:"allowPrivileged,omitempty" flag:"allow-privileged"` | ||
APIServerCount *int `json:"apiServerCount,omitempty" flag:"apiserver-count"` | ||
KubletPreferredAddressTypes []string `json:"kubletPreferredAddressTypes,omitempty" flag:"kubelet-preferred-address-types"` |
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.
Typo: Kublet
vs Kubelet
(in the field but more importantly in the JSON)
@@ -16,3 +16,7 @@ KubeAPIServer: | |||
LogLevel: 2 | |||
AllowPrivileged: true | |||
Image: {{ Image "kube-apiserver" }} | |||
KubletPreferredAddressTypes: |
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.
Will need to update this one also
@chrislovecnm I signed the CLA, all set there. @justinsb I fixed these typos, but am still struggling to verify locally. Any guidance on how to check that these flags are being passed? When I add them to the YAML options using |
@justinsb @chrislovecnm any updates on this? |
@@ -374,20 +374,21 @@ type KubeAPIServerConfig struct { | |||
|
|||
LogLevel int `json:"logLevel,omitempty" flag:"v"` | |||
|
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.
What's with the formatting here? Not that it should matter if it's just formatting - but do we need this in the PR?
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.
It's gofmt. The alternative is an extra line break to separate the fields.
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.
Sorry - I realized this flag isn't supported on 1.4 so needs more special treatment.
@@ -374,20 +374,21 @@ type KubeAPIServerConfig struct { | |||
|
|||
LogLevel int `json:"logLevel,omitempty" flag:"v"` | |||
|
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.
It's gofmt. The alternative is an extra line break to separate the fields.
@@ -16,3 +16,7 @@ KubeAPIServer: | |||
LogLevel: 2 | |||
AllowPrivileged: true | |||
Image: {{ Image "kube-apiserver" }} | |||
KubeletPreferredAddressTypes: |
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've realized you can only pass this in 1.5 or later.
I think you need to put this in a _k8s_1_5
magic directory (like we do for ConfigureCBR0, though the "other way round"). Or - if these are the defaults - simply not specify them unless you are overriding.
Are we changing the defaults here?
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.
followed the same pattern as AnonymousAuth
Just to let you know this #1183 will probably impact this PR. I appreciate your patience, and help! This PR is a big change that has some huge benefits. |
@chrislovecnm thanks for the response -- anything I need to be doing? |
@vjm we good to go? |
@chrislovecnm now we are! updated and working |
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.
We need documentation for this in a markdown please. Also you have two choices :)
- include unit tests
- file an issue for a unit test ~ and do it before your next PR.
Thanks
Chris
@@ -251,7 +251,7 @@ examples: | |||
|
|||
apimachinery: | |||
#go install ./cmd/libs/go2idl/conversion-gen | |||
~/k8s/bin/conversion-gen --input-dirs k8s.io/kops/pkg/apis/kops/v1alpha1 --v=8 --output-file-base=zz_generated.conversion | |||
${GOPATH}/bin/conversion-gen --skip-unsafe=true --input-dirs k8s.io/kops/pkg/apis/kops/v1alpha1 --v=8 --output-file-base=zz_generated.conversion |
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.
Can we back this out? If needed can we put it in a separate commit at least?
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.
Not a PR a commit
@@ -380,6 +380,8 @@ type KubeAPIServerConfig struct { | |||
RuntimeConfig map[string]string `json:"runtimeConfig,omitempty" flag:"runtime-config"` | |||
|
|||
AnonymousAuth *bool `json:"anonymousAuth,omitempty" flag:"anonymous-auth"` | |||
|
|||
KubeletPreferredAddressTypes []string `json:"kubeletPreferredAddressTypes,omitempty" flag:"kubelet-preferred-address-types"` |
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.
should we add documentation on wth this thing is?
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.
Probably not worth it for these - they directly map to the flags. Eventually this will be part of the k8s API, and we'll be able to delete this one.
@@ -377,6 +377,8 @@ type KubeAPIServerConfig struct { | |||
RuntimeConfig map[string]string `json:"runtimeConfig,omitempty" flag:"runtime-config"` | |||
|
|||
AnonymousAuth *bool `json:"anonymousAuth,omitempty" flag:"anonymous-auth"` | |||
|
|||
KubeletPreferredAddressTypes []string `json:"kubeletPreferredAddressTypes,omitempty" flag:"kubelet-preferred-address-types"` |
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.
pkg/apis/kops/v1alpha1/componentconfig.go
I think we need pkg/apis/kops/v1alpha2/componentconfig.go
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 think it's there?
@@ -199,8 +199,7 @@ func autoConvert_v1alpha1_ClusterSpec_To_kops_ClusterSpec(in *ClusterSpec, out * | |||
if in.Topology != nil { | |||
in, out := &in.Topology, &out.Topology | |||
*out = new(kops.TopologySpec) | |||
// TODO: Inefficient conversion - can we improve it? |
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.
Can you file an issue please.
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 is autogen
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.
LGTM. I presume that's a merge conflict on the Makefile change, but that a rebase will fix it
@@ -380,6 +380,8 @@ type KubeAPIServerConfig struct { | |||
RuntimeConfig map[string]string `json:"runtimeConfig,omitempty" flag:"runtime-config"` | |||
|
|||
AnonymousAuth *bool `json:"anonymousAuth,omitempty" flag:"anonymous-auth"` | |||
|
|||
KubeletPreferredAddressTypes []string `json:"kubeletPreferredAddressTypes,omitempty" flag:"kubelet-preferred-address-types"` |
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.
Probably not worth it for these - they directly map to the flags. Eventually this will be part of the k8s API, and we'll be able to delete this one.
@@ -133,6 +133,10 @@ type KubeAPIServerConfig struct { | |||
// for KubeAPIServer, concatenated with commas. ex: `--runtime-config=key1=value1,key2=value2`. | |||
// Use this to enable alpha resources on kube-apiserver | |||
RuntimeConfig map[string]string `json:"runtimeConfig,omitempty" flag:"runtime-config"` | |||
|
|||
AnonymousAuth *bool `json:"anonymousAuth,omitempty" flag:"anonymous-auth"` |
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.
Oops - nice find :-)
@@ -199,8 +199,7 @@ func autoConvert_v1alpha1_ClusterSpec_To_kops_ClusterSpec(in *ClusterSpec, out * | |||
if in.Topology != nil { | |||
in, out := &in.Topology, &out.Topology | |||
*out = new(kops.TopologySpec) | |||
// TODO: Inefficient conversion - can we improve it? |
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 is autogen
@@ -377,6 +377,8 @@ type KubeAPIServerConfig struct { | |||
RuntimeConfig map[string]string `json:"runtimeConfig,omitempty" flag:"runtime-config"` | |||
|
|||
AnonymousAuth *bool `json:"anonymousAuth,omitempty" flag:"anonymous-auth"` | |||
|
|||
KubeletPreferredAddressTypes []string `json:"kubeletPreferredAddressTypes,omitempty" flag:"kubelet-preferred-address-types"` |
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 think it's there?
LGTM - thanks :-) |
#1074
This change is![Reviewable](https://camo.githubusercontent.com/bdad2d5a4be7a00dc3b2426ea57eabd73ef84d8ed5ee05653b2f1501b6ea93ab/68747470733a2f2f72657669657761626c652e6b756265726e657465732e696f2f7265766965775f627574746f6e2e737667)