Documentation ¶
Index ¶
- Variables
- func ConvertLabelKey(key string) string
- func ConvertNamespacedLabelKey(physicalNamespace, key string) string
- func EqualExcept(a map[string]string, b map[string]string, except ...string) bool
- func IsManaged(obj runtime.Object) bool
- func IsManagedCluster(physicalNamespace string, obj runtime.Object) bool
- func LabelsClusterEqual(physicalNamespace string, virtualLabels map[string]string, ...) bool
- func LabelsEqual(virtualNamespace string, virtualLabels map[string]string, ...) bool
- func NamespaceLabelValue(virtualNamespace string) string
- func ObjectPhysicalName(obj runtime.Object) string
- func PhysicalName(name, namespace string) string
- func PhysicalNameClusterScoped(name, physicalNamespace string) string
- func ResetObjectMetadata(obj metav1.Object)
- func SafeConcatGenerateName(name ...string) string
- func SafeConcatName(name ...string) string
- func SetExcept(from map[string]string, to map[string]string, except ...string) map[string]string
- func SetupMetadata(targetNamespace string, obj runtime.Object) (runtime.Object, error)
- func SetupMetadataCluster(targetNamespace string, vObj runtime.Object, translator PhysicalNameTranslator) (runtime.Object, error)
- func Split(s, sep string) (string, string)
- func TranslateLabelSelector(labelSelector *metav1.LabelSelector) *metav1.LabelSelector
- func TranslateLabelSelectorCluster(physicalNamespace string, labelSelector *metav1.LabelSelector) *metav1.LabelSelector
- func TranslateLabels(virtualNamespace string, labels map[string]string) map[string]string
- func TranslateLabelsCluster(physicalNamespace string, labels map[string]string) map[string]string
- func UniqueSlice(stringSlice []string) []string
- type PhysicalNameTranslator
Constants ¶
This section is empty.
Variables ¶
View Source
var ( NamespaceLabel = "vcluster.loft.sh/namespace" MarkerLabel = "vcluster.loft.sh/managed-by" Suffix = "suffix" )
View Source
var OwningStatefulSet *appsv1.StatefulSet
Functions ¶
func ConvertLabelKey ¶ added in v0.3.0
func ConvertNamespacedLabelKey ¶ added in v0.4.0
func EqualExcept ¶
func IsManagedCluster ¶ added in v0.4.0
func LabelsClusterEqual ¶ added in v0.4.0
func LabelsEqual ¶ added in v0.3.0
func NamespaceLabelValue ¶ added in v0.3.0
func ObjectPhysicalName ¶
ObjectPhysicalName returns the translated physical name of this object
func PhysicalName ¶
PhysicalName returns the physical name of the name / namespace resource
func PhysicalNameClusterScoped ¶ added in v0.4.0
PhysicalNameClusterScoped returns the physical name of a cluster scoped object in the host cluster
func ResetObjectMetadata ¶
ResetObjectMetadata resets the objects metadata except name, namespace and annotations
func SafeConcatGenerateName ¶ added in v0.3.0
func SafeConcatName ¶
func SetupMetadata ¶
func SetupMetadataCluster ¶ added in v0.4.0
func TranslateLabelSelector ¶ added in v0.3.0
func TranslateLabelSelector(labelSelector *metav1.LabelSelector) *metav1.LabelSelector
func TranslateLabelSelectorCluster ¶ added in v0.4.0
func TranslateLabelSelectorCluster(physicalNamespace string, labelSelector *metav1.LabelSelector) *metav1.LabelSelector
func TranslateLabels ¶ added in v0.3.0
TranslateLabels transforms the virtual labels into physical ones
func TranslateLabelsCluster ¶ added in v0.4.0
TranslateLabelsCluster transforms the virtual labels into physical ones
func UniqueSlice ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.