mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-09 13:12:20 +00:00
make v1 enabled by default
This commit is contained in:
@@ -164,7 +164,6 @@ func startComponents(firstManifestURL, secondManifestURL, apiVersion string) (st
|
||||
ReadWritePort: portNumber,
|
||||
PublicAddress: publicAddress,
|
||||
CacheTimeout: 2 * time.Second,
|
||||
EnableV1: true,
|
||||
})
|
||||
handler.delegate = m.Handler
|
||||
|
||||
|
@@ -282,8 +282,10 @@ func (s *APIServer) Run(_ []string) error {
|
||||
disableV1beta3 := disableAllAPIs
|
||||
disableV1beta3 = !s.getRuntimeConfigValue("api/v1beta3", !disableV1beta3)
|
||||
|
||||
// V1 is disabled by default. Users can enable it using "api/v1={true}".
|
||||
_, enableV1 := s.RuntimeConfig["api/v1"]
|
||||
// "api/v1={true|false} allows users to enable/disable v1 API.
|
||||
// This takes preference over api/all and api/legacy, if specified.
|
||||
disableV1 := disableAllAPIs
|
||||
disableV1 = !s.getRuntimeConfigValue("api/v1", !disableV1)
|
||||
|
||||
// TODO: expose same flags as client.BindClientConfigFlags but for a server
|
||||
clientConfig := &client.Config{
|
||||
@@ -371,7 +373,7 @@ func (s *APIServer) Run(_ []string) error {
|
||||
Authorizer: authorizer,
|
||||
AdmissionControl: admissionController,
|
||||
DisableV1Beta3: disableV1beta3,
|
||||
EnableV1: enableV1,
|
||||
DisableV1: disableV1,
|
||||
MasterServiceNamespace: s.MasterServiceNamespace,
|
||||
ClusterName: s.ClusterName,
|
||||
ExternalHost: s.ExternalHost,
|
||||
|
Reference in New Issue
Block a user