Use const for kube-system namespace

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
This commit is contained in:
Brad Davidson 2020-09-23 23:06:00 -07:00
parent f59e8fc21b
commit ae916c2dec

View File

@ -17,6 +17,7 @@ import (
"github.com/rancher/k3s/pkg/version"
"github.com/rancher/wrangler-api/pkg/generated/controllers/core"
"github.com/sirupsen/logrus"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)
func (c *Cluster) newListener(ctx context.Context) (net.Listener, http.Handler, error) {
@ -84,5 +85,5 @@ func tlsStorage(ctx context.Context, dataDir string, runtime *config.ControlRunt
cache := memory.NewBacked(fileStorage)
return kubernetes.New(ctx, func() *core.Factory {
return runtime.Core
}, "kube-system", ""+version.Program+"-serving", cache)
}, metav1.NamespaceSystem, version.Program+"-serving", cache)
}