Documentation ¶
Overview ¶
+kubebuilder:validation:Optional +groupName=work.open-cluster-management.io
Index ¶
- Constants
- Variables
- func Resource(resource string) schema.GroupResource
- type AppliedManifestResourceMeta
- type AppliedManifestWork
- type AppliedManifestWorkList
- type AppliedManifestWorkSpec
- type AppliedManifestWorkStatus
- type Manifest
- type ManifestCondition
- type ManifestConditionType
- type ManifestResourceMeta
- type ManifestResourceStatus
- type ManifestWork
- type ManifestWorkList
- type ManifestWorkSpec
- type ManifestWorkStatus
- type ManifestsTemplate
Constants ¶
const ( // WorkProgressing represents that the work is in the progress to be // applied on the managed cluster. WorkProgressing string = "Progressing" // WorkApplied represents that the workload defined in work is // succesfully applied on the managed cluster. WorkApplied string = "Applied" // WorkAvailable represents that all resources of the work exists on // the managed cluster. WorkAvailable string = "Available" // WorkDegraded represents that the current state of work does not match // the desired state for a certain period. WorkDegraded string = "Degraded" )
Variables ¶
var ( GroupName = "work.open-cluster-management.io" GroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} // Install is a function which adds this version to a scheme Install = schemeBuilder.AddToScheme // SchemeGroupVersion generated code relies on this name // Deprecated SchemeGroupVersion = GroupVersion // AddToScheme exists solely to keep the old generators creating valid code // DEPRECATED AddToScheme = schemeBuilder.AddToScheme )
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource generated code relies on this being here, but it logically belongs to the group DEPRECATED
Types ¶
type AppliedManifestResourceMeta ¶
type AppliedManifestResourceMeta struct { // Group is the API Group of the Kubernetes resource. // +required Group string `json:"group"` // Version is the version of the Kubernetes resource. // +required Version string `json:"version"` // Resource is the resource name of the Kubernetes resource. // +required Resource string `json:"resource"` // Name is the name of the Kubernetes resource. // +required Name string `json:"name"` // Name is the namespace of the Kubernetes resource, empty string indicates // it is a cluster scoped resource. // +required Namespace string `json:"namespace"` // UID is set on successful deletion of the Kubernetes resource by controller. The // resource might be still visible on the managed cluster after this field is set. // It is not directly settable by a client. // +optional UID string `json:"uid,omitempty"` }
AppliedManifestResourceMeta represents the group, version, resource, name and namespace of a resource. Since these resources have been created, they must have valid group, version, resource, namespace, and name.
func (*AppliedManifestResourceMeta) DeepCopy ¶
func (in *AppliedManifestResourceMeta) DeepCopy() *AppliedManifestResourceMeta
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppliedManifestResourceMeta.
func (*AppliedManifestResourceMeta) DeepCopyInto ¶
func (in *AppliedManifestResourceMeta) DeepCopyInto(out *AppliedManifestResourceMeta)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (AppliedManifestResourceMeta) SwaggerDoc ¶
func (AppliedManifestResourceMeta) SwaggerDoc() map[string]string
type AppliedManifestWork ¶
type AppliedManifestWork struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Spec represents the desired configuration of AppliedManifestWork. Spec AppliedManifestWorkSpec `json:"spec,omitempty"` // Status represents the current status of AppliedManifestWork. // +optional Status AppliedManifestWorkStatus `json:"status,omitempty"` }
AppliedManifestWork represents an applied manifestwork on managed cluster that is placed on a managed cluster. An AppliedManifestWork links to a manifestwork on a hub recording resources deployed in the managed cluster. When the agent is removed from managed cluster, cluster-admin on managed cluster can delete appliedmanifestwork to remove resources deployed by the agent. The name of the appliedmanifestwork must be in the format of {hash of hub's first kube-apiserver url}-{manifestwork name}
func (*AppliedManifestWork) DeepCopy ¶
func (in *AppliedManifestWork) DeepCopy() *AppliedManifestWork
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppliedManifestWork.
func (*AppliedManifestWork) DeepCopyInto ¶
func (in *AppliedManifestWork) DeepCopyInto(out *AppliedManifestWork)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*AppliedManifestWork) DeepCopyObject ¶
func (in *AppliedManifestWork) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (AppliedManifestWork) SwaggerDoc ¶
func (AppliedManifestWork) SwaggerDoc() map[string]string
type AppliedManifestWorkList ¶
type AppliedManifestWorkList struct { metav1.TypeMeta `json:",inline"` // Standard list metadata. // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional metav1.ListMeta `json:"metadata,omitempty"` // Items is a list of appliedmanifestworks. Items []AppliedManifestWork `json:"items"` }
AppliedManifestWorkList is a collection of appliedmanifestworks.
func (*AppliedManifestWorkList) DeepCopy ¶
func (in *AppliedManifestWorkList) DeepCopy() *AppliedManifestWorkList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppliedManifestWorkList.
func (*AppliedManifestWorkList) DeepCopyInto ¶
func (in *AppliedManifestWorkList) DeepCopyInto(out *AppliedManifestWorkList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*AppliedManifestWorkList) DeepCopyObject ¶
func (in *AppliedManifestWorkList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (AppliedManifestWorkList) SwaggerDoc ¶
func (AppliedManifestWorkList) SwaggerDoc() map[string]string
type AppliedManifestWorkSpec ¶
type AppliedManifestWorkSpec struct { // HubHash represents the hash of the first hub kube apiserver to identify which hub // this AppliedManifestWork links to. // +required HubHash string `json:"hubHash"` // ManifestWorkName represents the name of the related manifestwork on the hub. // +required ManifestWorkName string `json:"manifestWorkName"` }
AppliedManifestWorkSpec represents the desired configuration of AppliedManifestWork
func (*AppliedManifestWorkSpec) DeepCopy ¶
func (in *AppliedManifestWorkSpec) DeepCopy() *AppliedManifestWorkSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppliedManifestWorkSpec.
func (*AppliedManifestWorkSpec) DeepCopyInto ¶
func (in *AppliedManifestWorkSpec) DeepCopyInto(out *AppliedManifestWorkSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (AppliedManifestWorkSpec) SwaggerDoc ¶
func (AppliedManifestWorkSpec) SwaggerDoc() map[string]string
type AppliedManifestWorkStatus ¶
type AppliedManifestWorkStatus struct { // AppliedResources represents a list of resources defined within the manifestwork that are applied. // Only resources with valid GroupVersionResource, namespace, and name are suitable. // An item in this slice is deleted when there is no mapped manifest in manifestwork.Spec or by finalizer. // The resource relating to the item will also be removed from managed cluster. // The deleted resource may still be present until the finalizers for that resource are finished. // However, the resource will not be undeleted, so it can be removed from this list and eventual consistency is preserved. // +optional AppliedResources []AppliedManifestResourceMeta `json:"appliedResources,omitempty"` }
AppliedManifestWorkStatus represents the current status of AppliedManifestWork
func (*AppliedManifestWorkStatus) DeepCopy ¶
func (in *AppliedManifestWorkStatus) DeepCopy() *AppliedManifestWorkStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppliedManifestWorkStatus.
func (*AppliedManifestWorkStatus) DeepCopyInto ¶
func (in *AppliedManifestWorkStatus) DeepCopyInto(out *AppliedManifestWorkStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (AppliedManifestWorkStatus) SwaggerDoc ¶
func (AppliedManifestWorkStatus) SwaggerDoc() map[string]string
type Manifest ¶
type Manifest struct { // +kubebuilder:validation:EmbeddedResource // +kubebuilder:pruning:PreserveUnknownFields runtime.RawExtension `json:",inline"` }
Manifest represents a resource to be deployed on managed cluster.
func (*Manifest) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Manifest.
func (*Manifest) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (Manifest) SwaggerDoc ¶
type ManifestCondition ¶
type ManifestCondition struct { // ResourceMeta represents the group, version, kind, name and namespace of a resoure. // +required ResourceMeta ManifestResourceMeta `json:"resourceMeta"` // Conditions represents the conditions of this resource on a managed cluster. // +required Conditions []metav1.Condition `json:"conditions"` }
ManifestCondition represents the conditions of the resources deployed on a managed cluster.
func (*ManifestCondition) DeepCopy ¶
func (in *ManifestCondition) DeepCopy() *ManifestCondition
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestCondition.
func (*ManifestCondition) DeepCopyInto ¶
func (in *ManifestCondition) DeepCopyInto(out *ManifestCondition)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ManifestCondition) SwaggerDoc ¶
func (ManifestCondition) SwaggerDoc() map[string]string
type ManifestConditionType ¶
type ManifestConditionType string
ManifestConditionType represents the condition type of a single resource manifest deployed on the managed cluster.
const ( // ManifestProgressing represents that the resource is being applied on the managed cluster ManifestProgressing ManifestConditionType = "Progressing" // ManifestApplied represents that the resource object is applied // on the managed cluster. ManifestApplied ManifestConditionType = "Applied" // ManifestAvailable represents that the resource object exists // on the managed cluster. ManifestAvailable ManifestConditionType = "Available" // ManifestDegraded represents that the current state of resource object does not // match the desired state for a certain period. ManifestDegraded ManifestConditionType = "Degraded" )
type ManifestResourceMeta ¶
type ManifestResourceMeta struct { // Ordinal represents the index of the manifest on spec. // +required Ordinal int32 `json:"ordinal"` // Group is the API Group of the Kubernetes resource. // +optional Group string `json:"group"` // Version is the version of the Kubernetes resource. // +optional Version string `json:"version"` // Kind is the kind of the Kubernetes resource. // +optional Kind string `json:"kind"` // Resource is the resource name of the Kubernetes resource. // +optional Resource string `json:"resource"` // Name is the name of the Kubernetes resource. // +optional Name string `json:"name"` // Name is the namespace of the Kubernetes resource. // +optional Namespace string `json:"namespace"` }
ManifestResourceMeta represents the group, version, kind, as well as the group, version, resource, name and namespace of a resoure.
func (*ManifestResourceMeta) DeepCopy ¶
func (in *ManifestResourceMeta) DeepCopy() *ManifestResourceMeta
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestResourceMeta.
func (*ManifestResourceMeta) DeepCopyInto ¶
func (in *ManifestResourceMeta) DeepCopyInto(out *ManifestResourceMeta)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ManifestResourceMeta) SwaggerDoc ¶
func (ManifestResourceMeta) SwaggerDoc() map[string]string
type ManifestResourceStatus ¶
type ManifestResourceStatus struct { // Manifests represents the condition of manifests deployed on managed cluster. // Valid condition types are: // 1. Progressing represents the resource is being applied on managed cluster. // 2. Applied represents the resource is applied successfully on managed cluster. // 3. Available represents the resource exists on the managed cluster. // 4. Degraded represents the current state of resource does not match the desired // state for a certain period. Manifests []ManifestCondition `json:"manifests,omitempty"` }
ManifestResourceStatus represents the status of each resource in manifest work deployed on managed cluster
func (*ManifestResourceStatus) DeepCopy ¶
func (in *ManifestResourceStatus) DeepCopy() *ManifestResourceStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestResourceStatus.
func (*ManifestResourceStatus) DeepCopyInto ¶
func (in *ManifestResourceStatus) DeepCopyInto(out *ManifestResourceStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ManifestResourceStatus) SwaggerDoc ¶
func (ManifestResourceStatus) SwaggerDoc() map[string]string
type ManifestWork ¶
type ManifestWork struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Spec represents a desired configuration of work to be deployed on the managed cluster. Spec ManifestWorkSpec `json:"spec"` // Status represents the current status of work. // +optional Status ManifestWorkStatus `json:"status,omitempty"` }
ManifestWork represents a manifests workload that hub wants to deploy on the managed cluster. A manifest workload is defined as a set of Kubernetes resources. ManifestWork must be created in the cluster namespace on the hub, so that agent on the corresponding managed cluster can access this resource and deploy on the managed cluster.
func (*ManifestWork) DeepCopy ¶
func (in *ManifestWork) DeepCopy() *ManifestWork
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestWork.
func (*ManifestWork) DeepCopyInto ¶
func (in *ManifestWork) DeepCopyInto(out *ManifestWork)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ManifestWork) DeepCopyObject ¶
func (in *ManifestWork) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (ManifestWork) SwaggerDoc ¶
func (ManifestWork) SwaggerDoc() map[string]string
type ManifestWorkList ¶
type ManifestWorkList struct { metav1.TypeMeta `json:",inline"` // Standard list metadata. // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional metav1.ListMeta `json:"metadata,omitempty"` // Items is a list of manifestworks. Items []ManifestWork `json:"items"` }
ManifestWorkList is a collection of manifestworks.
func (*ManifestWorkList) DeepCopy ¶
func (in *ManifestWorkList) DeepCopy() *ManifestWorkList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestWorkList.
func (*ManifestWorkList) DeepCopyInto ¶
func (in *ManifestWorkList) DeepCopyInto(out *ManifestWorkList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ManifestWorkList) DeepCopyObject ¶
func (in *ManifestWorkList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (ManifestWorkList) SwaggerDoc ¶
func (ManifestWorkList) SwaggerDoc() map[string]string
type ManifestWorkSpec ¶
type ManifestWorkSpec struct { // Workload represents the manifest workload to be deployed on a managed cluster. Workload ManifestsTemplate `json:"workload,omitempty"` }
ManifestWorkSpec represents a desired configuration of manifests to be deployed on the managed cluster.
func (*ManifestWorkSpec) DeepCopy ¶
func (in *ManifestWorkSpec) DeepCopy() *ManifestWorkSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestWorkSpec.
func (*ManifestWorkSpec) DeepCopyInto ¶
func (in *ManifestWorkSpec) DeepCopyInto(out *ManifestWorkSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ManifestWorkSpec) SwaggerDoc ¶
func (ManifestWorkSpec) SwaggerDoc() map[string]string
type ManifestWorkStatus ¶
type ManifestWorkStatus struct { // Conditions contains the different condition statuses for this work. // Valid condition types are: // 1. Applied represents workload in ManifestWork is applied successfully on managed cluster. // 2. Progressing represents workload in ManifestWork is being applied on managed cluster. // 3. Available represents workload in ManifestWork exists on the managed cluster. // 4. Degraded represents the current state of workload does not match the desired // state for a certain period. Conditions []metav1.Condition `json:"conditions,omitempty"` // ResourceStatus represents the status of each resource in manifestwork deployed on a // managed cluster. The Klusterlet agent on managed cluster syncs the condition from the managed cluster to the hub. // +optional ResourceStatus ManifestResourceStatus `json:"resourceStatus,omitempty"` }
ManifestWorkStatus represents the current status of managed cluster ManifestWork.
func (*ManifestWorkStatus) DeepCopy ¶
func (in *ManifestWorkStatus) DeepCopy() *ManifestWorkStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestWorkStatus.
func (*ManifestWorkStatus) DeepCopyInto ¶
func (in *ManifestWorkStatus) DeepCopyInto(out *ManifestWorkStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ManifestWorkStatus) SwaggerDoc ¶
func (ManifestWorkStatus) SwaggerDoc() map[string]string
type ManifestsTemplate ¶
type ManifestsTemplate struct { // Manifests represents a list of kuberenetes resources to be deployed on a managed cluster. // +optional Manifests []Manifest `json:"manifests,omitempty"` }
ManifestsTemplate represents the manifest workload to be deployed on a managed cluster.
func (*ManifestsTemplate) DeepCopy ¶
func (in *ManifestsTemplate) DeepCopy() *ManifestsTemplate
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestsTemplate.
func (*ManifestsTemplate) DeepCopyInto ¶
func (in *ManifestsTemplate) DeepCopyInto(out *ManifestsTemplate)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ManifestsTemplate) SwaggerDoc ¶
func (ManifestsTemplate) SwaggerDoc() map[string]string