File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
pkg/controlplane/apiserver Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -95,7 +95,9 @@ type Extra struct {
95
95
VersionedInformers clientgoinformers.SharedInformerFactory
96
96
}
97
97
98
- // BuildGenericConfig takes the master server options and produces the genericapiserver.Config associated with it
98
+ // BuildGenericConfig takes the generic controlplane apiserver options and produces
99
+ // the genericapiserver.Config associated with it. The genericapiserver.Config is
100
+ // often shared between multiple delegated apiservers.
99
101
func BuildGenericConfig (
100
102
s controlplaneapiserver.CompletedOptions ,
101
103
schemes []* runtime.Scheme ,
@@ -130,7 +132,7 @@ func BuildGenericConfig(
130
132
kubeClientConfig := genericConfig .LoopbackClientConfig
131
133
clientgoExternalClient , err := clientgoclientset .NewForConfig (kubeClientConfig )
132
134
if err != nil {
133
- lastErr = fmt .Errorf ("failed to create real external clientset: %v " , err )
135
+ lastErr = fmt .Errorf ("failed to create real external clientset: %w " , err )
134
136
return
135
137
}
136
138
versionedInformers = clientgoinformers .NewSharedInformerFactory (clientgoExternalClient , 10 * time .Minute )
@@ -203,7 +205,7 @@ func BuildGenericConfig(
203
205
versionedInformers ,
204
206
)
205
207
if err != nil {
206
- lastErr = fmt .Errorf ("invalid authorization config: %v " , err )
208
+ lastErr = fmt .Errorf ("invalid authorization config: %w " , err )
207
209
return
208
210
}
209
211
if s .Authorization != nil && ! enablesRBAC {
You can’t perform that action at this time.
0 commit comments