Documentation ¶
Overview ¶
Package v1 contains API Schema definitions for the discovery v1 API group +kubebuilder:object:generate=true +groupName=discovery.open-cluster-management.io
Index ¶
- Constants
- Variables
- func IsStringValid(s string) bool
- func IsSupportedClusterType(clusterType string) bool
- func ValidatingWebhook(namespace string) *admissionregistration.ValidatingWebhookConfiguration
- type DiscoveredCluster
- func (in *DiscoveredCluster) DeepCopy() *DiscoveredCluster
- func (in *DiscoveredCluster) DeepCopyInto(out *DiscoveredCluster)
- func (in *DiscoveredCluster) DeepCopyObject() runtime.Object
- func (r *DiscoveredCluster) Default()
- func (a DiscoveredCluster) Equal(b DiscoveredCluster) bool
- func (r *DiscoveredCluster) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (r *DiscoveredCluster) ValidateCreate() (admission.Warnings, error)
- func (r *DiscoveredCluster) ValidateDelete() (admission.Warnings, error)
- func (r *DiscoveredCluster) ValidateUpdate(old runtime.Object) (admission.Warnings, error)
- type DiscoveredClusterCondition
- type DiscoveredClusterConditionType
- type DiscoveredClusterList
- type DiscoveredClusterSpec
- type DiscoveredClusterStatus
- type DiscoveryConfig
- type DiscoveryConfigList
- type DiscoveryConfigSpec
- type DiscoveryConfigStatus
- type Filter
- type Semver
Constants ¶
const ( // AutoDetectLabels is used to specify automatic detection. AutoDetectLabels = "auto-detect" // ClusterMonitoringLabel is the label indicating cluster monitoring. ClusterMonitoringLabel = "openshift.io/cluster-monitoring" // CreatedViaAnnotation is the annotation indicating the creation method. CreatedViaAnnotation = "open-cluster-management/created-via" // ImportStrategyAnnotation is the annotation indicating the import strategy. ImportStrategyAnnotation = "discovery.open-cluster-management.io/import-strategy" // ImportCleanUpFinalizer is a cleanup finalizer associated with resources created by the discovery operator. ImportCleanUpFinalizer = "discovery.open-cluster-management.io/import-cleanup" )
Constants for labels and annotations used in discovery and management operations.
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "discovery.open-cluster-management.io", Version: "v1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
var (
Client cl.Client
)
log is for logging in this package.
Functions ¶
func IsStringValid ¶
IsStringValid returns true if the string conforms to the RFC 1123 standards.
func IsSupportedClusterType ¶
IsSupportedClusterType returns true if the cluster type is supported by the registry
func ValidatingWebhook ¶
func ValidatingWebhook(namespace string) *admissionregistration.ValidatingWebhookConfiguration
ValidatingWebhook returns the ValidatingWebhookConfiguration used for the discoveredcluster linked to a service in the provided namespace
Types ¶
type DiscoveredCluster ¶
type DiscoveredCluster struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec DiscoveredClusterSpec `json:"spec,omitempty"` Status DiscoveredClusterStatus `json:"status,omitempty"` }
DiscoveredCluster is the Schema for the discoveredclusters API
func (*DiscoveredCluster) DeepCopy ¶
func (in *DiscoveredCluster) DeepCopy() *DiscoveredCluster
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveredCluster.
func (*DiscoveredCluster) DeepCopyInto ¶
func (in *DiscoveredCluster) DeepCopyInto(out *DiscoveredCluster)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DiscoveredCluster) DeepCopyObject ¶
func (in *DiscoveredCluster) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*DiscoveredCluster) Default ¶
func (r *DiscoveredCluster) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (DiscoveredCluster) Equal ¶
func (a DiscoveredCluster) Equal(b DiscoveredCluster) bool
Equal reports whether the spec of a is equal to b.
func (*DiscoveredCluster) SetupWebhookWithManager ¶
func (r *DiscoveredCluster) SetupWebhookWithManager(mgr ctrl.Manager) error
func (*DiscoveredCluster) ValidateCreate ¶
func (r *DiscoveredCluster) ValidateCreate() (admission.Warnings, error)
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*DiscoveredCluster) ValidateDelete ¶
func (r *DiscoveredCluster) ValidateDelete() (admission.Warnings, error)
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
func (*DiscoveredCluster) ValidateUpdate ¶
ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
type DiscoveredClusterCondition ¶
type DiscoveredClusterCondition struct { // Type is the type of the discovered cluster condition. // +required Type DiscoveredClusterConditionType `json:"type,omitempty"` // Status is the status of the condition. One of True, False, Unknown. // +required Status metav1.ConditionStatus `json:"status,omitempty"` // The last time this condition was updated. LastUpdateTime metav1.Time `json:"lastUpdateTime,omitempty"` // LastTransitionTime is the last time the condition changed from one status to another. LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty"` }
func (*DiscoveredClusterCondition) DeepCopy ¶
func (in *DiscoveredClusterCondition) DeepCopy() *DiscoveredClusterCondition
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveredClusterCondition.
func (*DiscoveredClusterCondition) DeepCopyInto ¶
func (in *DiscoveredClusterCondition) DeepCopyInto(out *DiscoveredClusterCondition)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DiscoveredClusterConditionType ¶
type DiscoveredClusterConditionType string
const ( DiscoveredClusterActive DiscoveredClusterConditionType = "Available" DiscoveredClusterReserved DiscoveredClusterConditionType = "Reserved" DiscoveredClusterStale DiscoveredClusterConditionType = "Stale" )
These are valid conditions of the multiclusterengine.
type DiscoveredClusterList ¶
type DiscoveredClusterList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []DiscoveredCluster `json:"items"` }
DiscoveredClusterList contains a list of DiscoveredCluster
func (*DiscoveredClusterList) DeepCopy ¶
func (in *DiscoveredClusterList) DeepCopy() *DiscoveredClusterList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveredClusterList.
func (*DiscoveredClusterList) DeepCopyInto ¶
func (in *DiscoveredClusterList) DeepCopyInto(out *DiscoveredClusterList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DiscoveredClusterList) DeepCopyObject ¶
func (in *DiscoveredClusterList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type DiscoveredClusterSpec ¶
type DiscoveredClusterSpec struct { // ActivityTimestamp ... ActivityTimestamp *metav1.Time `json:"activityTimestamp,omitempty" yaml:"activityTimestamp,omitempty"` // APIURL ... APIURL string `json:"apiUrl" yaml:"apiUrl"` // CloudProvider ... CloudProvider string `json:"cloudProvider,omitempty" yaml:"cloudProvider,omitempty"` // Console ... Console string `json:"console,omitempty" yaml:"console,omitempty"` // CreationTimestamp ... CreationTimestamp *metav1.Time `json:"creationTimestamp,omitempty" yaml:"creationTimestamp,omitempty"` // Credential ... Credential corev1.ObjectReference `json:"credential,omitempty" yaml:"credential,omitempty"` // DisplayName ... DisplayName string `json:"displayName" yaml:"displayName"` // ImportAsManagedCluster ... // +kubebuilder:default:=false ImportAsManagedCluster bool `json:"importAsManagedCluster,omitempty" yaml:"importAsManagedCluster,omitempty"` // IsManagedCluster ... IsManagedCluster bool `json:"isManagedCluster" yaml:"isManagedCluster"` // Name ... Name string `json:"name" yaml:"name"` // OCPClusterID ... OCPClusterID string `json:"ocpClusterId,omitempty" yaml:"ocpClusterId,omitempty"` // OpenshiftVersion ... OpenshiftVersion string `json:"openshiftVersion,omitempty" yaml:"openshiftVersion,omitempty"` // Owner ... Owner string `json:"owner,omitempty" yaml:"owner,omitempty"` // RHOCMClusterID ... RHOCMClusterID string `json:"rhocmClusterId,omitempty" yaml:"rhocmClusterId,omitempty"` // Region ... Region string `json:"region,omitempty" yaml:"region,omitempty"` // Status ... Status string `json:"status,omitempty" yaml:"status,omitempty"` // Type ... Type string `json:"type" yaml:"type"` }
DiscoveredClusterSpec defines the desired state of DiscoveredCluster
func (*DiscoveredClusterSpec) DeepCopy ¶
func (in *DiscoveredClusterSpec) DeepCopy() *DiscoveredClusterSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveredClusterSpec.
func (*DiscoveredClusterSpec) DeepCopyInto ¶
func (in *DiscoveredClusterSpec) DeepCopyInto(out *DiscoveredClusterSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DiscoveredClusterStatus ¶
type DiscoveredClusterStatus struct { // INSERT ADDITIONAL STATUS FIELD - define observed state of cluster // Important: Run "make" to regenerate code after modifying this file Conditions []DiscoveredClusterCondition `json:"conditions,omitempty"` }
DiscoveredClusterStatus defines the observed state of DiscoveredCluster
func (*DiscoveredClusterStatus) DeepCopy ¶
func (in *DiscoveredClusterStatus) DeepCopy() *DiscoveredClusterStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveredClusterStatus.
func (*DiscoveredClusterStatus) DeepCopyInto ¶
func (in *DiscoveredClusterStatus) DeepCopyInto(out *DiscoveredClusterStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DiscoveryConfig ¶
type DiscoveryConfig struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec DiscoveryConfigSpec `json:"spec,omitempty"` Status DiscoveryConfigStatus `json:"status,omitempty"` }
DiscoveryConfig is the Schema for the discoveryconfigs API
func (*DiscoveryConfig) DeepCopy ¶
func (in *DiscoveryConfig) DeepCopy() *DiscoveryConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveryConfig.
func (*DiscoveryConfig) DeepCopyInto ¶
func (in *DiscoveryConfig) DeepCopyInto(out *DiscoveryConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DiscoveryConfig) DeepCopyObject ¶
func (in *DiscoveryConfig) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type DiscoveryConfigList ¶
type DiscoveryConfigList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []DiscoveryConfig `json:"items"` }
DiscoveryConfigList contains a list of DiscoveryConfig
func (*DiscoveryConfigList) DeepCopy ¶
func (in *DiscoveryConfigList) DeepCopy() *DiscoveryConfigList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveryConfigList.
func (*DiscoveryConfigList) DeepCopyInto ¶
func (in *DiscoveryConfigList) DeepCopyInto(out *DiscoveryConfigList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DiscoveryConfigList) DeepCopyObject ¶
func (in *DiscoveryConfigList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type DiscoveryConfigSpec ¶
type DiscoveryConfigSpec struct { // Credential is the secret containing credentials to connect to the OCM api on behalf of a user // +required Credential string `json:"credential"` // Sets restrictions on what kind of clusters to discover // +optional Filters Filter `json:"filters,omitempty"` }
DiscoveryConfigSpec defines the desired state of DiscoveryConfig
func (*DiscoveryConfigSpec) DeepCopy ¶
func (in *DiscoveryConfigSpec) DeepCopy() *DiscoveryConfigSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveryConfigSpec.
func (*DiscoveryConfigSpec) DeepCopyInto ¶
func (in *DiscoveryConfigSpec) DeepCopyInto(out *DiscoveryConfigSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DiscoveryConfigStatus ¶
type DiscoveryConfigStatus struct { }
DiscoveryConfigStatus defines the observed state of DiscoveryConfig
func (*DiscoveryConfigStatus) DeepCopy ¶
func (in *DiscoveryConfigStatus) DeepCopy() *DiscoveryConfigStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveryConfigStatus.
func (*DiscoveryConfigStatus) DeepCopyInto ¶
func (in *DiscoveryConfigStatus) DeepCopyInto(out *DiscoveryConfigStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Filter ¶
type Filter struct { // LastActive is the last active in days of clusters to discover, determined by activity timestamp // +optional LastActive int `json:"lastActive,omitempty"` // OpenShiftVersions is the list of release versions of OpenShift of the form "<Major>.<Minor>" // +optional OpenShiftVersions []Semver `json:"openShiftVersions,omitempty"` }
Filter ...
func (*Filter) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Filter.
func (*Filter) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.