Documentation
¶
Index ¶
- func ApplyManifestsFile(dynamicClient dynamic.Interface, manifestFile string) error
- func GetCAPIClusterNameAndContext(data ClusterNameData) (string, string, error)
- func ListAllNamespacesWithPrefix(k8sClient *kubernetes.Clientset, prefix string) ([]string, error)
- func MergeKubeconfigs(srcKubeconfig, dstKubeconfigPath string) error
- func RepoRoot() string
- func ResourcesExist(restConfig *rest.Config, namespace string, resourceName string, ...) (bool, error)
- func WaitAllResourcesReady(clusterAuth k8sclient.ClusterAuthInfo, namespaces []string, ...) error
- func WaitForCRDs(config *rest.Config, crds []string) error
- type ClusterNameData
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyManifestsFile ¶
ApplyManifestsFile applies all manifests in a provided file
func GetCAPIClusterNameAndContext ¶
func GetCAPIClusterNameAndContext(data ClusterNameData) (string, string, error)
GetCAPIClusterCtxName generates a CAPI cluster context name using a template and data.
func ListAllNamespacesWithPrefix ¶
func ListAllNamespacesWithPrefix(k8sClient *kubernetes.Clientset, prefix string) ([]string, error)
ListAllNamespaces lists all namespaces in the cluster if prefix is provided only namespace with this prefix are returned
func MergeKubeconfigs ¶
mergeKubeconfigs merges the content of srcKubeconfig into dstKubeconfigPath. srcKubeconfig is a kubeconfig file in a string form dstKubeconfigPath is the path to the destination kubeconfig file, which already contains other content. TODO - this should not be a ClusterAPI method
func ResourcesExist ¶
func WaitAllResourcesReady ¶
func WaitAllResourcesReady(clusterAuth k8sclient.ClusterAuthInfo, namespaces []string, gvr []schema.GroupVersionResource) error
WaitAllResourcesReady waits for all specified resources to be ready in the given namespaces. If namespaces array is empty the function returns immediatelly
Types ¶
type ClusterNameData ¶
type ClusterNameData struct {
Name string
}