Documentation ¶
Index ¶
- Constants
- Variables
- func AcceptManagedCluster(clusterName string) error
- func AddLabels(obj *unstructured.Unstructured, labels map[string]string) error
- func ApplyClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func CheckClusterID(obj *unstructured.Unstructured) error
- func CheckDistributionInfo(obj *unstructured.Unstructured) error
- func CheckFoundationPodsReady() error
- func CreateClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func CreateManagedCluster(dynamicClient dynamic.Interface) (*unstructured.Unstructured, error)
- func CreateManagedClusterSet(dynamicClient dynamic.Interface) (*unstructured.Unstructured, error)
- func CreateResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func DeleteClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, name string) error
- func DeleteManagedCluster(dynamicClient dynamic.Interface, clusterName string) error
- func DeleteManagedClusterSet(dynamicClient dynamic.Interface, clusterSetName string) error
- func DeleteResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) error
- func GenerateCSR(clusterNamespace, clusterName string, key []byte) (string, error)
- func GeneratePrivateKey() ([]byte, 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 GetHostFromClientConfig() (string, error)
- func GetJoinedManagedClusters(dynamicClient dynamic.Interface) ([]*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 ListResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) ([]*unstructured.Unstructured, error)
- func LoadResourceFromJSON(json string) (*unstructured.Unstructured, error)
- func NewAPIServiceClient() (*apiregistrationclient.ApiregistrationV1Client, error)
- func NewDynamicClient() (dynamic.Interface, error)
- func NewDynamicClientWithImpersonate(user string, groups []string) (dynamic.Interface, error)
- func NewHiveClient() (hiveclient.Interface, error)
- func NewKubeClient() (kubernetes.Interface, error)
- func NewKubeConfig() (*rest.Config, error)
- func SetStatusType(obj *unstructured.Unstructured, statusType string) error
- func SetSubjects(obj *unstructured.Unstructured, newSubject rbacv1.Subject) error
- func UpdateClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func UpdateResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
- func UpdateResourceStatus(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, ...) (*unstructured.Unstructured, error)
Constants ¶
View Source
const BMATemplate = `` /* 402-byte string literal not displayed */
View Source
const ClusterRoleBindingTemplate = `` /* 433-byte string literal not displayed */
View Source
const ClusterRoleTemplate = `` /* 424-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 ManagedClusterSetRandomTemplate = `` /* 167-byte string literal not displayed */
View Source
const ManagedClusterSetTemplate = `` /* 143-byte string literal not displayed */
View Source
const ManagedClusterTemplate = `` /* 299-byte string literal not displayed */
ManagedClusterTemplate is json template for namespace
View Source
const ManagedClusterViewTemplate = `` /* 395-byte string literal not displayed */
ManagedClusterViewTemplate is json template for namespace
View Source
const NamespaceTemplate = `` /* 155-byte string literal not displayed */
NamespaceTemplate is json template for namespace
Variables ¶
View Source
var ClusterRoleBindingGVR = schema.GroupVersionResource{
Group: "rbac.authorization.k8s.io",
Version: "v1",
Resource: "clusterrolebindings",
}
View Source
var ClusterRoleGVR = schema.GroupVersionResource{
Group: "rbac.authorization.k8s.io",
Version: "v1",
Resource: "clusterroles",
}
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: "v1alpha1",
Resource: "managedclustersets",
}
View Source
var NamespaceGVR = schema.GroupVersionResource{
Group: "",
Version: "v1",
Resource: "namespaces",
}
Functions ¶
func AcceptManagedCluster ¶
func AddLabels ¶
func AddLabels(obj *unstructured.Unstructured, labels map[string]string) error
func ApplyClusterResource ¶
func ApplyClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func CheckClusterID ¶
func CheckClusterID(obj *unstructured.Unstructured) error
func CheckDistributionInfo ¶
func CheckDistributionInfo(obj *unstructured.Unstructured) error
func CheckFoundationPodsReady ¶
func CheckFoundationPodsReady() error
func CreateClusterResource ¶
func CreateClusterResource( dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func CreateManagedCluster ¶
func CreateManagedCluster(dynamicClient dynamic.Interface) (*unstructured.Unstructured, error)
func CreateManagedClusterSet ¶
func CreateManagedClusterSet(dynamicClient dynamic.Interface) (*unstructured.Unstructured, error)
func CreateResource ¶
func CreateResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func DeleteClusterResource ¶
func DeleteManagedCluster ¶
func DeleteManagedClusterSet ¶
func DeleteResource ¶
func GenerateCSR ¶
func GeneratePrivateKey ¶
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 GetHostFromClientConfig ¶
func GetJoinedManagedClusters ¶
func GetJoinedManagedClusters(dynamicClient dynamic.Interface) ([]*unstructured.Unstructured, error)
func GetResource ¶
func GetResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, namespace, name string) (*unstructured.Unstructured, error)
func HasClusterResource ¶
func HasResource ¶
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 NewDynamicClient ¶
func NewHiveClient ¶
func NewHiveClient() (hiveclient.Interface, error)
func NewKubeClient ¶
func NewKubeClient() (kubernetes.Interface, error)
func NewKubeConfig ¶
func SetStatusType ¶
func SetStatusType(obj *unstructured.Unstructured, statusType string) error
func SetSubjects ¶
func SetSubjects(obj *unstructured.Unstructured, newSubject rbacv1.Subject) error
func UpdateClusterResource ¶
func UpdateClusterResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func UpdateResource ¶
func UpdateResource(dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func UpdateResourceStatus ¶
func UpdateResourceStatus( dynamicClient dynamic.Interface, gvr schema.GroupVersionResource, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.