Documentation ¶
Index ¶
- Variables
- func DumpSecret(coreV1Client corev1client.CoreV1Interface, ...) error
- func GenerateBootstrapStatusUpdater() clientcert.StatusUpdateFunc
- func GenerateStatusUpdater(hubClusterClient clientset.Interface, ...) clientcert.StatusUpdateFunc
- func GetClusterAgentNamesFromCertificate(certData []byte) (clusterName, agentName string, err error)
- func NewClientCertForHubController(clusterName string, agentName string, clientCertSecretNamespace string, ...) factory.Controller
- func NewHubKubeconfigSecretController(hubKubeconfigDir, hubKubeconfigSecretNamespace, hubKubeconfigSecretName string, ...) factory.Controller
- func NewManagedClusterCreatingController(clusterName string, spokeExternalServerURLs []string, ...) factory.Controller
Constants ¶
This section is empty.
Variables ¶
var ( // CreatingControllerSyncInterval is exposed so that integration tests can crank up the controller sync speed. CreatingControllerSyncInterval = 60 * time.Minute )
Functions ¶
func DumpSecret ¶
func DumpSecret( coreV1Client corev1client.CoreV1Interface, secretNamespace, secretName, outputDir string, ctx context.Context, recorder events.Recorder) error
DumpSecret dumps the data in the given seccret into a directory in file system. The output directory will be created if not exists. TO DO: remove the file once the corresponding key is removed from secret.
func GenerateBootstrapStatusUpdater ¶
func GenerateBootstrapStatusUpdater() clientcert.StatusUpdateFunc
func GenerateStatusUpdater ¶
func GenerateStatusUpdater(hubClusterClient clientset.Interface, hubClusterLister clusterv1listers.ManagedClusterLister, clusterName string) clientcert.StatusUpdateFunc
GenerateStatusUpdater generates status update func for the certificate management
func GetClusterAgentNamesFromCertificate ¶
func GetClusterAgentNamesFromCertificate(certData []byte) (clusterName, agentName string, err error)
GetClusterAgentNamesFromCertificate returns the cluster name and agent name by parsing the common name of the certification
func NewClientCertForHubController ¶
func NewClientCertForHubController( clusterName string, agentName string, clientCertSecretNamespace string, clientCertSecretName string, kubeconfigData []byte, spokeSecretInformer corev1informers.SecretInformer, csrControl clientcert.CSRControl, csrExpirationSeconds int32, spokeKubeClient kubernetes.Interface, statusUpdater clientcert.StatusUpdateFunc, recorder events.Recorder, controllerName string, ) factory.Controller
NewClientCertForHubController returns a controller to 1). Create a new client certificate and build a hub kubeconfig for the registration agent; 2). Or rotate the client certificate referenced by the hub kubeconfig before it become expired;
func NewHubKubeconfigSecretController ¶
func NewHubKubeconfigSecretController( hubKubeconfigDir, hubKubeconfigSecretNamespace, hubKubeconfigSecretName string, spokeCoreClient corev1client.CoreV1Interface, spokeSecretInformer corev1informers.SecretInformer, recorder events.Recorder) factory.Controller
NewHubKubeconfigSecretController returns a new HubKubeconfigSecretController
func NewManagedClusterCreatingController ¶
func NewManagedClusterCreatingController( clusterName string, spokeExternalServerURLs []string, annotations map[string]string, spokeCABundle []byte, hubClusterClient clientset.Interface, recorder events.Recorder) factory.Controller
NewManagedClusterCreatingController creates a new managedClusterCreatingController on the managed cluster.
Types ¶
This section is empty.