Documentation ¶
Index ¶
- Constants
- func CurrentContext() (string, *clientcmdapi.Config, error)
- func FormatOptions(format string, options [][]string) []string
- func GetPodStatus(pod *corev1.Pod) string
- func SwitchContext(kubeConfig *clientcmdapi.Config, otherContext string) error
- func VClusterConnectBackgroundProxyName(vClusterName string, vClusterNamespace string, currentContext string) string
- func VClusterContextName(vClusterName string, vClusterNamespace string, currentContext string) string
- func VClusterFromContext(originalContext string) (name string, namespace string, context string)
- func VClusterProContextName(vClusterName string, projectName string, currentContext string) string
- func VClusterProFromContext(originalContext string) (name string, project string, context string)
- type Status
- type VCluster
- func GetVCluster(ctx context.Context, proClient procli.Client, ...) (*VCluster, *procli.VirtualClusterInstanceProject, error)
- func ListOSSVClusters(ctx context.Context, context, name, namespace string) ([]VCluster, error)
- func ListVClusters(ctx context.Context, proClient procli.Client, ...) ([]VCluster, []procli.VirtualClusterInstanceProject, error)
- type VclusterNotFoundError
Constants ¶
View Source
const VirtualClusterSelector = "app=vcluster"
Variables ¶
This section is empty.
Functions ¶
func CurrentContext ¶
func CurrentContext() (string, *clientcmdapi.Config, error)
func FormatOptions ¶ added in v0.16.0
func GetPodStatus ¶
GetPodStatus returns the pod status as a string Taken from https://github.com/kubernetes/kubernetes/pkg/printers/internalversion/printers.go
func SwitchContext ¶ added in v0.16.0
func SwitchContext(kubeConfig *clientcmdapi.Config, otherContext string) error
func VClusterConnectBackgroundProxyName ¶ added in v0.11.2
func VClusterContextName ¶
func VClusterFromContext ¶
func VClusterProContextName ¶ added in v0.16.0
Types ¶
type VCluster ¶
type VCluster struct { Name string Namespace string Status Status Created metav1.Time Context string Version string ClientFactory clientcmd.ClientConfig `json:"-"` }
func GetVCluster ¶
func ListOSSVClusters ¶ added in v0.16.0
type VclusterNotFoundError ¶ added in v0.19.0
type VclusterNotFoundError struct {
Name string
}
func (*VclusterNotFoundError) Error ¶ added in v0.19.0
func (e *VclusterNotFoundError) Error() string
Click to show internal directories.
Click to hide internal directories.