package kubeconfig
import "k8s.io/kubernetes/cmd/kubeadm/app/phases/kubeconfig"
Index ¶
- Constants
- func CreateAdminAndKubeletKubeConfig(masterEndpoint, pkiDir, outDir string) error
- func MakeClientConfigWithCerts(serverURL, clusterName, userName string, caCert []byte, clientKey []byte, clientCert []byte) *clientcmdapi.Config
- func MakeClientConfigWithToken(serverURL, clusterName, userName string, caCert []byte, token string) *clientcmdapi.Config
- func WriteKubeconfigToDisk(filename string, kubeconfig *clientcmdapi.Config) error
Constants ¶
const ( KubernetesDirPermissions = 0700 KubeConfigFilePermissions = 0600 AdminKubeConfigFileName = "admin.conf" AdminKubeConfigClientName = "kubernetes-admin" KubeletKubeConfigFileName = "kubelet.conf" KubeletKubeConfigClientName = "kubelet" )
Functions ¶
func CreateAdminAndKubeletKubeConfig ¶
CreateAdminAndKubeletKubeConfig is called from the main init and does the work for the default phase behaviour
func MakeClientConfigWithCerts ¶
func MakeClientConfigWithCerts(serverURL, clusterName, userName string, caCert []byte, clientKey []byte, clientCert []byte) *clientcmdapi.Config
Creates a clientcmdapi.Config object with access to the API server with client certificates
func MakeClientConfigWithToken ¶
func MakeClientConfigWithToken(serverURL, clusterName, userName string, caCert []byte, token string) *clientcmdapi.Config
Creates a clientcmdapi.Config object with access to the API server with a token
func WriteKubeconfigToDisk ¶
func WriteKubeconfigToDisk(filename string, kubeconfig *clientcmdapi.Config) error
Source Files ¶
doc.go kubeconfig.go
- Version
- v1.6.0-alpha.1
- Published
- Jan 30, 2017
- Platform
- linux/amd64
- Imports
- 12 packages
- Last checked
- 10 minutes ago –
Tools for package owners.