import "k8s.io/kubernetes/test/utils/kubeconfig"
kubeconfig.go
func CreateKubeConfig(clientCfg *rest.Config) *clientcmdapi.Config
CreateKubeConfig converts a rest.Config into a clientcmdapi.Config which then can be written to a file with [clientcmd.WriteToFile].