File tree 3 files changed +6
-0
lines changed 3 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -52,6 +52,7 @@ import (
52
52
"sigs.k8s.io/cluster-api/feature"
53
53
bootstrapv1alpha3 "sigs.k8s.io/cluster-api/internal/apis/bootstrap/kubeadm/v1alpha3"
54
54
bootstrapv1alpha4 "sigs.k8s.io/cluster-api/internal/apis/bootstrap/kubeadm/v1alpha4"
55
+ "sigs.k8s.io/cluster-api/util/apiwarnings"
55
56
"sigs.k8s.io/cluster-api/util/flags"
56
57
"sigs.k8s.io/cluster-api/version"
57
58
)
@@ -201,6 +202,7 @@ func main() {
201
202
restConfig .QPS = restConfigQPS
202
203
restConfig .Burst = restConfigBurst
203
204
restConfig .UserAgent = remote .DefaultClusterAPIUserAgent (controllerName )
205
+ restConfig .WarningHandler = apiwarnings .DefaultHandler (klog .Background ().WithName ("API Server Warning" ))
204
206
205
207
tlsOptions , metricsOptions , err := flags .GetManagerOptions (managerOptions )
206
208
if err != nil {
Original file line number Diff line number Diff line change @@ -56,6 +56,7 @@ import (
56
56
"sigs.k8s.io/cluster-api/feature"
57
57
controlplanev1alpha3 "sigs.k8s.io/cluster-api/internal/apis/controlplane/kubeadm/v1alpha3"
58
58
controlplanev1alpha4 "sigs.k8s.io/cluster-api/internal/apis/controlplane/kubeadm/v1alpha4"
59
+ "sigs.k8s.io/cluster-api/util/apiwarnings"
59
60
"sigs.k8s.io/cluster-api/util/flags"
60
61
"sigs.k8s.io/cluster-api/version"
61
62
)
@@ -211,6 +212,7 @@ func main() {
211
212
restConfig .QPS = restConfigQPS
212
213
restConfig .Burst = restConfigBurst
213
214
restConfig .UserAgent = remote .DefaultClusterAPIUserAgent (controllerName )
215
+ restConfig .WarningHandler = apiwarnings .DefaultHandler (klog .Background ().WithName ("API Server Warning" ))
214
216
215
217
tlsOptions , metricsOptions , err := flags .GetManagerOptions (managerOptions )
216
218
if err != nil {
Original file line number Diff line number Diff line change @@ -72,6 +72,7 @@ import (
72
72
runtimeclient "sigs.k8s.io/cluster-api/internal/runtime/client"
73
73
runtimeregistry "sigs.k8s.io/cluster-api/internal/runtime/registry"
74
74
runtimewebhooks "sigs.k8s.io/cluster-api/internal/webhooks/runtime"
75
+ "sigs.k8s.io/cluster-api/util/apiwarnings"
75
76
"sigs.k8s.io/cluster-api/util/flags"
76
77
"sigs.k8s.io/cluster-api/version"
77
78
"sigs.k8s.io/cluster-api/webhooks"
@@ -270,6 +271,7 @@ func main() {
270
271
restConfig .QPS = restConfigQPS
271
272
restConfig .Burst = restConfigBurst
272
273
restConfig .UserAgent = remote .DefaultClusterAPIUserAgent (controllerName )
274
+ restConfig .WarningHandler = apiwarnings .DefaultHandler (klog .Background ().WithName ("API Server Warning" ))
273
275
274
276
minVer := version .MinimumKubernetesVersion
275
277
if feature .Gates .Enabled (feature .ClusterTopology ) {
You can’t perform that action at this time.
0 commit comments