mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
Creates new kube-public
namespace as a peer to kube-system
This commit is contained in:
parent
2ee7db4daf
commit
da93009d91
@ -41,9 +41,10 @@ import (
|
|||||||
|
|
||||||
const kubernetesServiceName = "kubernetes"
|
const kubernetesServiceName = "kubernetes"
|
||||||
|
|
||||||
// Controller is the controller manager for the core bootstrap Kubernetes controller
|
// Controller is the controller manager for the core bootstrap Kubernetes
|
||||||
// loops, which manage creating the "kubernetes" service, the "default" and "kube-system"
|
// controller loops, which manage creating the "kubernetes" service, the
|
||||||
// namespace, and provide the IP repair check on service IPs
|
// "default", "kube-system" and "kube-public" namespaces, and provide the IP
|
||||||
|
// repair check on service IPs
|
||||||
type Controller struct {
|
type Controller struct {
|
||||||
ServiceClient coreclient.ServicesGetter
|
ServiceClient coreclient.ServicesGetter
|
||||||
NamespaceClient coreclient.NamespacesGetter
|
NamespaceClient coreclient.NamespacesGetter
|
||||||
@ -84,7 +85,7 @@ func (c *Config) NewBootstrapController(legacyRESTStorage corerest.LegacyRESTSto
|
|||||||
EndpointReconciler: c.EndpointReconcilerConfig.Reconciler,
|
EndpointReconciler: c.EndpointReconcilerConfig.Reconciler,
|
||||||
EndpointInterval: c.EndpointReconcilerConfig.Interval,
|
EndpointInterval: c.EndpointReconcilerConfig.Interval,
|
||||||
|
|
||||||
SystemNamespaces: []string{metav1.NamespaceSystem},
|
SystemNamespaces: []string{metav1.NamespaceSystem, metav1.NamespacePublic},
|
||||||
SystemNamespacesInterval: 1 * time.Minute,
|
SystemNamespacesInterval: 1 * time.Minute,
|
||||||
|
|
||||||
ServiceClusterIPRegistry: legacyRESTStorage.ServiceClusterIPAllocator,
|
ServiceClusterIPRegistry: legacyRESTStorage.ServiceClusterIPAllocator,
|
||||||
|
@ -51,7 +51,7 @@ const (
|
|||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
admission.RegisterPlugin(PluginName, func(config io.Reader) (admission.Interface, error) {
|
admission.RegisterPlugin(PluginName, func(config io.Reader) (admission.Interface, error) {
|
||||||
return NewLifecycle(sets.NewString(metav1.NamespaceDefault, metav1.NamespaceSystem))
|
return NewLifecycle(sets.NewString(metav1.NamespaceDefault, metav1.NamespaceSystem, metav1.NamespacePublic))
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user