Documentation
¶
Index ¶
Constants ¶
const ( KymaFinalizer = OperatorGroup + Separator + string(KymaKind) PurgeFinalizer = OperatorGroup + Separator + "purge-finalizer" WatcherFinalizer = OperatorGroup + Separator + "watcher" MandatoryModuleFinalizer = OperatorGroup + Separator + "mandatory-module" )
const ( CACertificateName = "klm-watcher-serving" IstioNamespace = "istio-system" GatewaySecretName = "klm-istio-gateway" //nolint:gosec // It is just a name LastModifiedAtAnnotation = "lastModifiedAt" GCMSecretAnnotation = "cert.gardener.cloud/requestedAt" //nolint:gosec // It is just a name )
const ( DefaultControlPlaneNamespace = "kcp-system" DefaultRemoteNamespace = "kyma-system" )
const ( FQDN = OperatorGroup + Separator + "fqdn" // OwnedByAnnotation defines the resource managing the resource. Differing from ManagedBy // in that it does not reference controllers. Used by the runtime-watcher to determine the // corresponding CR in KCP. OwnedByAnnotation = OperatorGroup + Separator + "owned-by" OwnedByFormat = "%s/%s" IsClusterScopedAnnotation = OperatorGroup + Separator + "is-cluster-scoped" UnmanagedAnnotation = OperatorGroup + Separator + "is-unmanaged" )
const ( KymaGroup = "kyma-project.io" OperatorGroup = "operator." + KymaGroup Separator = "/" ControllerName = OperatorGroup + Separator + "controller-name" ChannelLabel = OperatorGroup + Separator + "channel" // ManagedBy defines the controller managing the resource. ManagedBy = OperatorGroup + Separator + "managed-by" ManagedByLabelValue = kymaValue IstioInjectionLabel = "istio-injection" WardenLabel = "namespaces.warden.kyma-project.io/validate" EnabledValue = "enabled" KymaName = OperatorGroup + Separator + "kyma-name" ModuleName = OperatorGroup + Separator + "module-name" IsMandatoryModule = OperatorGroup + Separator + "mandatory-module" OperatorName = "lifecycle-manager" // WatchedByLabel defines a redirect to a controller that should be getting a notification // if this resource is changed. WatchedByLabel = OperatorGroup + Separator + "watched-by" WatchedByLabelValue = kymaValue // PurposeLabel defines the purpose of the resource, i.e. Secrets which will be used to certificate management. PurposeLabel = OperatorGroup + Separator + "purpose" CertManager = "klm-watcher-cert-manager" // SkipReconcileLabel indicates this specific resource will be skipped during reconciliation. SkipReconcileLabel = OperatorGroup + Separator + "skip-reconciliation" UnmanagedKyma = "unmanaged-kyma" DefaultRemoteKymaName = "default" InternalLabel = OperatorGroup + Separator + "internal" BetaLabel = OperatorGroup + Separator + "beta" GlobalAccountIDLabel = KymaGroup + Separator + "global-account-id" SubAccountIDLabel = KymaGroup + Separator + "subaccount-id" RegionLabel = KymaGroup + Separator + "region" PlatformRegionLabel = KymaGroup + Separator + "platform-region" PlanLabel = KymaGroup + Separator + "broker-plan-name" RuntimeIDLabel = KymaGroup + Separator + "runtime-id" EnableLabelValue = "true" DisableLabelValue = "false" )
const (
InstanceIDLabel = "kyma-project.io/instance-id"
)
const (
// This annotation carries the FQDN of the shoot cluster, for example: "<shootid>.kyma.ondemand.com".
SkrDomainAnnotation = "skr-domain"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Channel ¶
type Channel string
const ( // NoneChannel when this value is defined for the ModuleTemplate, // it means that the ModuleTemplate is not assigned to any channel. NoneChannel Channel = "none" )
type LastOperation ¶
type LastOperation struct {
Operation string `json:"operation"`
LastUpdateTime apimetav1.Time `json:"lastUpdateTime,omitempty"`
}
LastOperation defines the last operation from the control-loop. +k8s:deepcopy-gen=true
func (*LastOperation) DeepCopy ¶
func (in *LastOperation) DeepCopy() *LastOperation
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LastOperation.
func (*LastOperation) DeepCopyInto ¶
func (in *LastOperation) DeepCopyInto(out *LastOperation)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Resource ¶
type Resource struct {
apimetav1.GroupVersionKind `json:",inline"`
Name string `json:"name"`
Namespace string `json:"namespace"`
}
+k8s:deepcopy-gen=true
func (*Resource) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Resource.
func (*Resource) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (Resource) ToUnstructured ¶
func (r Resource) ToUnstructured() *unstructured.Unstructured
type State ¶
type State string
+kubebuilder:validation:Enum=Processing;Deleting;Ready;Error;"";Warning;Unmanaged
const ( // StateReady signifies CustomObject is ready and has been installed successfully. StateReady State = "Ready" // StateProcessing signifies CustomObject is reconciling and is in the process of installation. // Processing can also signal that the Installation previously encountered an error and is now recovering. StateProcessing State = "Processing" // StateError signifies an error for CustomObject. This signifies that the Installation // process encountered an error. // Contrary to Processing, it can be expected that this state should change on the next retry. StateError State = "Error" // StateDeleting signifies CustomObject is being deleted. This is the state that is used // when a deletionTimestamp was detected and Finalizers are picked up. StateDeleting State = "Deleting" // StateWarning signifies specified resource has been deployed, but cannot be used due to misconfiguration, // usually it means that user interaction is required. StateWarning State = "Warning" StateUnmanaged State = "Unmanaged" )
Valid States.
func AllKymaStates ¶
func AllKymaStates() []State
func AllMandatoryModuleStates ¶
func AllMandatoryModuleStates() []State
func AllModuleStates ¶
func AllModuleStates() []State
func (State) IsSupportedState ¶
IsSupportedState These states will be used by module CR.
type Status ¶
type Status struct {
LastOperation `json:"lastOperation,omitempty"`
// State signifies current state of CustomObject.
// Value can be one of ("Ready", "Processing", "Error", "Deleting", "Warning").
// +kubebuilder:validation:Required
State State `json:"state,omitempty"`
// Conditions contain a set of conditionals to determine the State of Status.
// If all Conditions are met, the State is expected to be in StateReady.
// +listType=map
// +listMapKey=type
Conditions []apimetav1.Condition `json:"conditions,omitempty" patchMergeKey:"type" patchStrategy:"merge"`
// Synced determine a list of Resources that are currently actively synced.
// All resources that are synced are considered for orphan removal on configuration changes,
// and it is used to determine effective differences from one state to the next.
// +listType=atomic
Synced []Resource `json:"synced,omitempty"`
}
Status defines the observed state of CustomObject. +k8s:deepcopy-gen=true
func (*Status) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Status.
func (*Status) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.