Documentation ¶
Overview ¶
+kubebuilder:validation:Optional +groupName=insights.openshift.io Package v1alpha1 is the v1alpha1 version of the API.
Index ¶
- Constants
- Variables
- func Resource(resource string) schema.GroupResource
- type DataGather
- type DataGatherList
- type DataGatherSpec
- type DataGatherState
- type DataGatherStatus
- type DataPolicy
- type GathererConfig
- type GathererState
- type GathererStatus
- type HealthCheck
- type HealthCheckState
- type InsightsReport
- type ObjectReference
Constants ¶
const ( // No data obfuscation NoPolicy DataPolicy = "ClearText" // IP addresses and cluster domain name are obfuscated ObfuscateNetworking DataPolicy = "ObfuscateNetworking" // Data gathering is running Running DataGatherState = "Running" // Data gathering is completed Completed DataGatherState = "Completed" // Data gathering failed Failed DataGatherState = "Failed" // Data gathering is pending Pending DataGatherState = "Pending" // Gatherer state marked as disabled, which means that the gatherer will not run. Disabled GathererState = "Disabled" // Gatherer state marked as enabled, which means that the gatherer will run. Enabled GathererState = "Enabled" )
Variables ¶
var ( GroupName = "insights.openshift.io" GroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} // 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 DataGather ¶
type DataGather struct { metav1.TypeMeta `json:",inline"` // metadata is the standard object's metadata. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata metav1.ObjectMeta `json:"metadata,omitempty"` // spec holds user settable values for configuration // +required Spec DataGatherSpec `json:"spec"` // status holds observed values from the cluster. They may not be overridden. // +optional Status DataGatherStatus `json:"status"` }
+genclient +genclient:nonNamespaced +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true +kubebuilder:resource:path=datagathers,scope=Cluster +kubebuilder:subresource:status +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/1365 +openshift:file-pattern=cvoRunLevel=0000_10,operatorName=insights,operatorOrdering=01 +openshift:enable:FeatureGate=InsightsOnDemandDataGather +kubebuilder:printcolumn:name=State,type=string,JSONPath=.status.dataGatherState,description=DataGather job state +kubebuilder:printcolumn:name=StartTime,type=date,JSONPath=.status.startTime,description=DataGather start time +kubebuilder:printcolumn:name=FinishTime,type=date,JSONPath=.status.finishTime,description=DataGather finish time
DataGather provides data gather configuration options and status for the particular Insights data gathering.
Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support. +openshift:compatibility-gen:level=4
func (*DataGather) DeepCopy ¶
func (in *DataGather) DeepCopy() *DataGather
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DataGather.
func (*DataGather) DeepCopyInto ¶
func (in *DataGather) DeepCopyInto(out *DataGather)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DataGather) DeepCopyObject ¶
func (in *DataGather) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (DataGather) SwaggerDoc ¶
func (DataGather) SwaggerDoc() map[string]string
type DataGatherList ¶
type DataGatherList struct { metav1.TypeMeta `json:",inline"` // metadata is the standard list's metadata. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata metav1.ListMeta `json:"metadata"` // items contains a list of DataGather resources. Items []DataGather `json:"items"` }
DataGatherList is a collection of items
Compatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support. +openshift:compatibility-gen:level=4
func (*DataGatherList) DeepCopy ¶
func (in *DataGatherList) DeepCopy() *DataGatherList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DataGatherList.
func (*DataGatherList) DeepCopyInto ¶
func (in *DataGatherList) DeepCopyInto(out *DataGatherList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DataGatherList) DeepCopyObject ¶
func (in *DataGatherList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (DataGatherList) SwaggerDoc ¶
func (DataGatherList) SwaggerDoc() map[string]string
type DataGatherSpec ¶
type DataGatherSpec struct { // dataPolicy allows user to enable additional global obfuscation of the IP addresses and base domain // in the Insights archive data. Valid values are "ClearText" and "ObfuscateNetworking". // When set to ClearText the data is not obfuscated. // When set to ObfuscateNetworking the IP addresses and the cluster domain name are obfuscated. // When omitted, this means no opinion and the platform is left to choose a reasonable default, which is subject to change over time. // The current default is ClearText. // +optional DataPolicy DataPolicy `json:"dataPolicy"` // gatherers is a list of gatherers configurations. // The particular gatherers IDs can be found at https://github.com/openshift/insights-operator/blob/master/docs/gathered-data.md. // Run the following command to get the names of last active gatherers: // "oc get insightsoperators.operator.openshift.io cluster -o json | jq '.status.gatherStatus.gatherers[].name'" // +optional Gatherers []GathererConfig `json:"gatherers"` }
DataGatherSpec contains the configuration for the DataGather.
func (*DataGatherSpec) DeepCopy ¶
func (in *DataGatherSpec) DeepCopy() *DataGatherSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DataGatherSpec.
func (*DataGatherSpec) DeepCopyInto ¶
func (in *DataGatherSpec) DeepCopyInto(out *DataGatherSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (DataGatherSpec) SwaggerDoc ¶
func (DataGatherSpec) SwaggerDoc() map[string]string
type DataGatherState ¶
type DataGatherState string
dataGatherState declares valid gathering state types +kubebuilder:validation:Optional +kubebuilder:validation:Enum=Running;Completed;Failed;Pending +kubebuilder:validation:XValidation:rule="!(oldSelf == 'Running' && self == 'Pending')", message="dataGatherState cannot transition from Running to Pending" +kubebuilder:validation:XValidation:rule="!(oldSelf == 'Completed' && self == 'Pending')", message="dataGatherState cannot transition from Completed to Pending" +kubebuilder:validation:XValidation:rule="!(oldSelf == 'Failed' && self == 'Pending')", message="dataGatherState cannot transition from Failed to Pending" +kubebuilder:validation:XValidation:rule="!(oldSelf == 'Completed' && self == 'Running')", message="dataGatherState cannot transition from Completed to Running" +kubebuilder:validation:XValidation:rule="!(oldSelf == 'Failed' && self == 'Running')", message="dataGatherState cannot transition from Failed to Running"
type DataGatherStatus ¶
type DataGatherStatus struct { // conditions provide details on the status of the gatherer job. // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type // +optional Conditions []metav1.Condition `json:"conditions" patchStrategy:"merge" patchMergeKey:"type"` // dataGatherState reflects the current state of the data gathering process. // +optional State DataGatherState `json:"dataGatherState,omitempty"` // gatherers is a list of active gatherers (and their statuses) in the last gathering. // +listType=map // +listMapKey=name // +optional Gatherers []GathererStatus `json:"gatherers,omitempty"` // startTime is the time when Insights data gathering started. // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="startTime is immutable once set" // +optional StartTime metav1.Time `json:"startTime,omitempty"` // finishTime is the time when Insights data gathering finished. // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="finishTime is immutable once set" // +optional FinishTime metav1.Time `json:"finishTime,omitempty"` // relatedObjects is a list of resources which are useful when debugging or inspecting the data // gathering Pod // +optional RelatedObjects []ObjectReference `json:"relatedObjects,omitempty"` // insightsRequestID is an Insights request ID to track the status of the // Insights analysis (in console.redhat.com processing pipeline) for the corresponding Insights data archive. // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="insightsRequestID is immutable once set" // +optional InsightsRequestID string `json:"insightsRequestID,omitempty"` // insightsReport provides general Insights analysis results. // When omitted, this means no data gathering has taken place yet or the // corresponding Insights analysis (identified by "insightsRequestID") is not available. // +optional InsightsReport InsightsReport `json:"insightsReport,omitempty"` }
DataGatherStatus contains information relating to the DataGather state. +kubebuilder:validation:XValidation:rule="(!has(oldSelf.insightsRequestID) || has(self.insightsRequestID))",message="cannot remove insightsRequestID attribute from status" +kubebuilder:validation:XValidation:rule="(!has(oldSelf.startTime) || has(self.startTime))",message="cannot remove startTime attribute from status" +kubebuilder:validation:XValidation:rule="(!has(oldSelf.finishTime) || has(self.finishTime))",message="cannot remove finishTime attribute from status" +kubebuilder:validation:XValidation:rule="(!has(oldSelf.dataGatherState) || has(self.dataGatherState))",message="cannot remove dataGatherState attribute from status" +kubebuilder:validation:Optional
func (*DataGatherStatus) DeepCopy ¶
func (in *DataGatherStatus) DeepCopy() *DataGatherStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DataGatherStatus.
func (*DataGatherStatus) DeepCopyInto ¶
func (in *DataGatherStatus) DeepCopyInto(out *DataGatherStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (DataGatherStatus) SwaggerDoc ¶
func (DataGatherStatus) SwaggerDoc() map[string]string
type DataPolicy ¶
type DataPolicy string
dataPolicy declares valid data policy types +kubebuilder:validation:Enum="";ClearText;ObfuscateNetworking
type GathererConfig ¶
type GathererConfig struct { // name is the name of specific gatherer // +required Name string `json:"name"` // state allows you to configure specific gatherer. Valid values are "Enabled", "Disabled" and omitted. // When omitted, this means no opinion and the platform is left to choose a reasonable default. // The current default is Enabled. // +optional State GathererState `json:"state"` }
gathererConfig allows to configure specific gatherers
func (*GathererConfig) DeepCopy ¶
func (in *GathererConfig) DeepCopy() *GathererConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GathererConfig.
func (*GathererConfig) DeepCopyInto ¶
func (in *GathererConfig) DeepCopyInto(out *GathererConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (GathererConfig) SwaggerDoc ¶
func (GathererConfig) SwaggerDoc() map[string]string
type GathererState ¶
type GathererState string
state declares valid gatherer state types. +kubebuilder:validation:Enum="";Enabled;Disabled
type GathererStatus ¶
type GathererStatus struct { // conditions provide details on the status of each gatherer. // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type // +required // +kubebuilder:validation:MinItems=1 Conditions []metav1.Condition `json:"conditions" patchStrategy:"merge" patchMergeKey:"type"` // name is the name of the gatherer. // +required // +kubebuilder:validation:MaxLength=256 // +kubebuilder:validation:MinLength=5 Name string `json:"name"` // lastGatherDuration represents the time spent gathering. // +required // +kubebuilder:validation:Type=string // +kubebuilder:validation:Pattern="^(([0-9]+(?:\\.[0-9]+)?(ns|us|µs|μs|ms|s|m|h))+)$" LastGatherDuration metav1.Duration `json:"lastGatherDuration"` }
gathererStatus represents information about a particular data gatherer.
func (*GathererStatus) DeepCopy ¶
func (in *GathererStatus) DeepCopy() *GathererStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GathererStatus.
func (*GathererStatus) DeepCopyInto ¶
func (in *GathererStatus) DeepCopyInto(out *GathererStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (GathererStatus) SwaggerDoc ¶
func (GathererStatus) SwaggerDoc() map[string]string
type HealthCheck ¶
type HealthCheck struct { // description provides basic description of the healtcheck. // +required // +kubebuilder:validation:MaxLength=2048 // +kubebuilder:validation:MinLength=10 Description string `json:"description"` // totalRisk of the healthcheck. Indicator of the total risk posed // by the detected issue; combination of impact and likelihood. The values can be from 1 to 4, // and the higher the number, the more important the issue. // +required // +kubebuilder:validation:Minimum=1 // +kubebuilder:validation:Maximum=4 TotalRisk int32 `json:"totalRisk"` // advisorURI provides the URL link to the Insights Advisor. // +required // +kubebuilder:validation:Pattern=`^https:\/\/\S+` AdvisorURI string `json:"advisorURI"` // state determines what the current state of the health check is. // Health check is enabled by default and can be disabled // by the user in the Insights advisor user interface. // +required State HealthCheckState `json:"state"` }
healthCheck represents an Insights health check attributes.
func (*HealthCheck) DeepCopy ¶
func (in *HealthCheck) DeepCopy() *HealthCheck
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HealthCheck.
func (*HealthCheck) DeepCopyInto ¶
func (in *HealthCheck) DeepCopyInto(out *HealthCheck)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (HealthCheck) SwaggerDoc ¶
func (HealthCheck) SwaggerDoc() map[string]string
type HealthCheckState ¶
type HealthCheckState string
healthCheckState provides information about the status of the health check (for example, the health check may be marked as disabled by the user). +kubebuilder:validation:Enum:=Enabled;Disabled
const ( // enabled marks the health check as enabled HealthCheckEnabled HealthCheckState = "Enabled" // disabled marks the health check as disabled HealthCheckDisabled HealthCheckState = "Disabled" )
type InsightsReport ¶
type InsightsReport struct { // downloadedAt is the time when the last Insights report was downloaded. // An empty value means that there has not been any Insights report downloaded yet and // it usually appears in disconnected clusters (or clusters when the Insights data gathering is disabled). // +optional DownloadedAt metav1.Time `json:"downloadedAt,omitempty"` // healthChecks provides basic information about active Insights health checks // in a cluster. // +listType=atomic // +optional HealthChecks []HealthCheck `json:"healthChecks,omitempty"` // uri provides the URL link from which the report was downloaded. // +kubebuilder:validation:Pattern=`^https:\/\/\S+` // +optional URI string `json:"uri,omitempty"` }
insightsReport provides Insights health check report based on the most recently sent Insights data.
func (*InsightsReport) DeepCopy ¶
func (in *InsightsReport) DeepCopy() *InsightsReport
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InsightsReport.
func (*InsightsReport) DeepCopyInto ¶
func (in *InsightsReport) DeepCopyInto(out *InsightsReport)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (InsightsReport) SwaggerDoc ¶
func (InsightsReport) SwaggerDoc() map[string]string
type ObjectReference ¶
type ObjectReference struct { // group is the API Group of the Resource. // Enter empty string for the core group. // This value should consist of only lowercase alphanumeric characters, hyphens and periods. // Example: "", "apps", "build.openshift.io", etc. // +kubebuilder:validation:Pattern:="^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$" // +required Group string `json:"group"` // resource is the type that is being referenced. // It is normally the plural form of the resource kind in lowercase. // This value should consist of only lowercase alphanumeric characters and hyphens. // Example: "deployments", "deploymentconfigs", "pods", etc. // +required // +kubebuilder:validation:Pattern:="^[a-z0-9]([-a-z0-9]*[a-z0-9])?$" Resource string `json:"resource"` // name of the referent. // +required Name string `json:"name"` // namespace of the referent. // +optional Namespace string `json:"namespace,omitempty"` }
ObjectReference contains enough information to let you inspect or modify the referred object.
func (*ObjectReference) DeepCopy ¶
func (in *ObjectReference) DeepCopy() *ObjectReference
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ObjectReference.
func (*ObjectReference) DeepCopyInto ¶
func (in *ObjectReference) DeepCopyInto(out *ObjectReference)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ObjectReference) SwaggerDoc ¶
func (ObjectReference) SwaggerDoc() map[string]string