Documentation
¶
Index ¶
- Constants
- Variables
- func AcceptManagedCluster(hubClient kubernetes.Interface, clusterClient clusterclient.Interface, ...) error
- func CheckClusterID(obj *unstructured.Unstructured) error
- func CheckDistributionInfo(obj *unstructured.Unstructured) error
- func CheckJoinedManagedCluster(client clusterclient.Interface, clusterName string) error
- func CheckNodeList(obj *unstructured.Unstructured) error
- func ClaimCluster(hiveClient hiveclient.Interface, cdName, cdNs, claimName string) error
- func CleanManagedCluster(client clusterclient.Interface, clusterName string) error
- func CreateClusterClaim(hiveClient hiveclient.Interface, name, namespace, clusterPool string) error
- func CreateClusterDeployment(hiveClient hiveclient.Interface, ...) error
- func CreateClusterPool(hiveClient hiveclient.Interface, name, namespace string, ...) error
- func CreateClusterRole(kubeClient kubernetes.Interface, name string, rules []rbacv1.PolicyRule) error
- func CreateClusterRoleBinding(kubeClient kubernetes.Interface, name, clusterRole, user string) error
- func CreateClusterRoleBindingForUser(kubeClient kubernetes.Interface, name, clusterRole, user string) error
- func CreateFakeRootCaConfigMap(kubeClient kubernetes.Interface, name, namespace string) (*corev1.ConfigMap, error)
- func CreateFakeTlsSecret(kubeClient kubernetes.Interface, name, namespace string) (*corev1.Secret, error)
- func CreateImageRegistry(dynamicClient dynamic.Interface, ...) error
- func CreateManagedCluster(client clusterclient.Interface, cluster *clusterv1.ManagedCluster) error
- func CreateManagedClusterSet(client clusterclient.Interface, name string) error
- func CreateManagedClusterSetBinding(client clusterclient.Interface, namespace, name, clusterSetName string) error
- func CreateNamespace(name string) error
- func CreatePlacement(client clusterclient.Interface, namespace, name string, clusterSets []string, ...) error
- func CreatePullSecret(kubeClient kubernetes.Interface, namespace, name string) error
- func CreateResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func DeleteClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, name string) error
- func DeleteClusterRole(kubeClient kubernetes.Interface, name string) error
- func DeleteClusterRoleBinding(kubeClient kubernetes.Interface, name string) error
- func DeleteImageRegistry(dynamicClient dynamic.Interface, namespace, name string) error
- func DeleteManagedClusterSet(client clusterclient.Interface, name string) error
- func DeleteManagedClusterSetBinding(client clusterclient.Interface, namespace, name string) error
- func DeleteNamespace(name string) error
- func DeletePlacement(client clusterclient.Interface, namespace, name string) error
- func DeleteResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) error
- func GetClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, name string) (*unstructured.Unstructured, error)
- func GetConditionFromStatus(obj *unstructured.Unstructured) (map[string]interface{}, error)
- func GetConditionTypeFromStatus(obj *unstructured.Unstructured, typeName string) bool
- func GetImageRegistry(dynamicClient dynamic.Interface, namespace, name string) (*unstructured.Unstructured, error)
- func GetResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func HasClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, name string) (bool, error)
- func HasResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (bool, error)
- func ImportManagedCluster(client clusterclient.Interface, clusterName string) error
- func IsOCP(obj *unstructured.Unstructured) (bool, error)
- func ListResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) ([]*unstructured.Unstructured, error)
- func LoadResourceFromJSON(json string) (*unstructured.Unstructured, error)
- func NewAPIServiceClient() (*apiregistrationclient.ApiregistrationV1Client, error)
- func NewClusterClient() (clusterclient.Interface, error)
- func NewClusterClientWithImpersonate(user string, groups []string) (clusterclient.Interface, error)
- func NewDynamicClient() (dynamic.Interface, error)
- func NewDynamicClientWithImpersonate(user string, groups []string) (dynamic.Interface, error)
- func NewHiveClient() (hiveclient.Interface, error)
- func NewImageRegistryClient() (imageregistry.Client, error)
- func NewKubeClient() (kubernetes.Interface, error)
- func NewKubeConfig() (*rest.Config, error)
- func NewManagedCluster(name string) *clusterv1.ManagedCluster
- func NewManagedClusterSet(name string) *clusterv1beta1.ManagedClusterSet
- func NewManagedClusterSetBinding(namespace, name, clusterSetName string) *clusterv1beta1.ManagedClusterSetBinding
- func NewNamespace(name string) *v1.Namespace
- func NewOCPClient() (openshiftclientset.Interface, error)
- func RandomName() string
- func UpdateClusterPoolLabel(hiveClient hiveclient.Interface, name, namespace string, ...) error
- func UpdateClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func UpdateClusterRole(kubeClient kubernetes.Interface, name string, rules []rbacv1.PolicyRule) error
- func UpdateManagedClusterLabels(client clusterclient.Interface, clusterName string, labels map[string]string) error
Constants ¶
View Source
const BMATemplate = `` /* 402-byte string literal not displayed */
View Source
const ManagedClusterActionCreateTemplate = `` /* 1186-byte string literal not displayed */
ManagedClusterActionCreateTemplate is json template for create action
View Source
const ManagedClusterActionDeleteTemplate = `` /* 419-byte string literal not displayed */
ManagedClusterActionDeleteTemplate is json template for delete action
View Source
const ManagedClusterActionUpdateTemplate = `` /* 1184-byte string literal not displayed */
ManagedClusterActionUpdateTemplate is json template for update action
View Source
const ManagedClusterViewTemplate = `` /* 408-byte string literal not displayed */
ManagedClusterViewTemplate is json template for namespace
Variables ¶
View Source
var ClusterInfoGVR = schema.GroupVersionResource{
Group: "internal.open-cluster-management.io",
Version: "v1beta1",
Resource: "managedclusterinfos",
}
View Source
var ManagedClusterGVR schema.GroupVersionResource = schema.GroupVersionResource{
Group: "cluster.open-cluster-management.io",
Version: "v1",
Resource: "managedclusters",
}
View Source
var ManagedClusterSetGVR = schema.GroupVersionResource{
Group: "cluster.open-cluster-management.io",
Version: "v1beta1",
Resource: "managedclustersets",
}
Functions ¶
func AcceptManagedCluster ¶
func AcceptManagedCluster(hubClient kubernetes.Interface, clusterClient clusterclient.Interface, clusterName string) error
func CheckClusterID ¶
func CheckClusterID(obj *unstructured.Unstructured) error
func CheckDistributionInfo ¶
func CheckDistributionInfo(obj *unstructured.Unstructured) error
func CheckJoinedManagedCluster ¶
func CheckJoinedManagedCluster(client clusterclient.Interface, clusterName string) error
func CheckNodeList ¶
func CheckNodeList(obj *unstructured.Unstructured) error
func ClaimCluster ¶
func ClaimCluster(hiveClient hiveclient.Interface, cdName, cdNs, claimName string) error
func CleanManagedCluster ¶
func CleanManagedCluster(client clusterclient.Interface, clusterName string) error
func CreateClusterClaim ¶
func CreateClusterClaim(hiveClient hiveclient.Interface, name, namespace, clusterPool string) error
func CreateClusterDeployment ¶
func CreateClusterDeployment(hiveClient hiveclient.Interface, name, namespace, clusterPoolName, clusterPoolNamespace string) error
func CreateClusterPool ¶
func CreateClusterRole ¶
func CreateClusterRole(kubeClient kubernetes.Interface, name string, rules []rbacv1.PolicyRule) error
func CreateClusterRoleBinding ¶
func CreateClusterRoleBinding(kubeClient kubernetes.Interface, name, clusterRole, user string) error
func CreateClusterRoleBindingForUser ¶
func CreateClusterRoleBindingForUser(kubeClient kubernetes.Interface, name, clusterRole, user string) error
func CreateFakeTlsSecret ¶
func CreateImageRegistry ¶
func CreateManagedCluster ¶
func CreateManagedCluster(client clusterclient.Interface, cluster *clusterv1.ManagedCluster) error
func CreateManagedClusterSet ¶
func CreateManagedClusterSet(client clusterclient.Interface, name string) error
func CreateManagedClusterSetBinding ¶
func CreateManagedClusterSetBinding(client clusterclient.Interface, namespace, name, clusterSetName string) error
func CreateNamespace ¶
func CreatePlacement ¶
func CreatePullSecret ¶
func CreatePullSecret(kubeClient kubernetes.Interface, namespace, name string) error
func CreateResource ¶
func CreateResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func DeleteClusterResource ¶
func DeleteClusterRole ¶
func DeleteClusterRole(kubeClient kubernetes.Interface, name string) error
func DeleteClusterRoleBinding ¶
func DeleteClusterRoleBinding(kubeClient kubernetes.Interface, name string) error
func DeleteImageRegistry ¶
func DeleteManagedClusterSet ¶
func DeleteManagedClusterSet(client clusterclient.Interface, name string) error
func DeleteManagedClusterSetBinding ¶
func DeleteManagedClusterSetBinding(client clusterclient.Interface, namespace, name string) error
func DeleteNamespace ¶
func DeletePlacement ¶
func DeletePlacement(client clusterclient.Interface, namespace, name string) error
func DeleteResource ¶
func GetClusterResource ¶
func GetClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, name string) (*unstructured.Unstructured, error)
func GetConditionFromStatus ¶
func GetConditionFromStatus(obj *unstructured.Unstructured) (map[string]interface{}, error)
func GetConditionTypeFromStatus ¶
func GetConditionTypeFromStatus(obj *unstructured.Unstructured, typeName string) bool
func GetImageRegistry ¶
func GetImageRegistry(dynamicClient dynamic.Interface, namespace, name string) (*unstructured.Unstructured, error)
func GetResource ¶
func GetResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, namespace, name string) (*unstructured.Unstructured, error)
func HasClusterResource ¶
func HasResource ¶
func ImportManagedCluster ¶
func ImportManagedCluster(client clusterclient.Interface, clusterName string) error
func IsOCP ¶
func IsOCP(obj *unstructured.Unstructured) (bool, error)
Check if the current cluster is ocp by managedclusterinfo
func ListResource ¶
func ListResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, namespace, labelSelector string) ([]*unstructured.Unstructured, error)
func LoadResourceFromJSON ¶
func LoadResourceFromJSON(json string) (*unstructured.Unstructured, error)
func NewAPIServiceClient ¶
func NewAPIServiceClient() (*apiregistrationclient.ApiregistrationV1Client, error)
func NewClusterClient ¶
func NewClusterClient() (clusterclient.Interface, error)
func NewClusterClientWithImpersonate ¶
func NewClusterClientWithImpersonate(user string, groups []string) (clusterclient.Interface, error)
func NewDynamicClient ¶
func NewHiveClient ¶
func NewHiveClient() (hiveclient.Interface, error)
func NewImageRegistryClient ¶
func NewImageRegistryClient() (imageregistry.Client, error)
func NewKubeClient ¶
func NewKubeClient() (kubernetes.Interface, error)
func NewKubeConfig ¶
func NewManagedCluster ¶
func NewManagedCluster(name string) *clusterv1.ManagedCluster
func NewManagedClusterSet ¶
func NewManagedClusterSet(name string) *clusterv1beta1.ManagedClusterSet
func NewManagedClusterSetBinding ¶
func NewManagedClusterSetBinding(namespace, name, clusterSetName string) *clusterv1beta1.ManagedClusterSetBinding
func NewNamespace ¶
func NewOCPClient ¶
func NewOCPClient() (openshiftclientset.Interface, error)
func RandomName ¶
func RandomName() string
func UpdateClusterPoolLabel ¶
func UpdateClusterResource ¶
func UpdateClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func UpdateClusterRole ¶
func UpdateClusterRole(kubeClient kubernetes.Interface, name string, rules []rbacv1.PolicyRule) error
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.