From fe40b648edf32de1dfdf0fac770f83093e9d0b7a Mon Sep 17 00:00:00 2001 From: mfordjody <11638005@qq.com> Date: Sun, 8 Dec 2024 11:59:00 +0800 Subject: [PATCH] [operator] Add k8s client factory --- pkg/kube/client_factory.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 pkg/kube/client_factory.go diff --git a/pkg/kube/client_factory.go b/pkg/kube/client_factory.go new file mode 100644 index 00000000..c2d89ddb --- /dev/null +++ b/pkg/kube/client_factory.go @@ -0,0 +1,12 @@ +package kube + +import "k8s.io/client-go/tools/clientcmd" + +type clientFactory struct { + clientConfig clientcmd.ClientConfig +} + +func newClientFactory(clientConfig clientcmd.ClientConfig, diskCache bool) *clientFactory { + cf := &clientFactory{clientConfig: clientConfig} + return cf +}