v1

package
v0.8.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 10, 2021 License: Apache-2.0 Imports: 8 Imported by: 128

Documentation

Overview

Package v1 contains resources types for version v1 of the operators.coreos.com API group.

Package v1 contains API Schema definitions for the operator v1 API group.

Index

Constants

View Source
const (
	OperatorGroupAnnotationKey             = "olm.operatorGroup"
	OperatorGroupNamespaceAnnotationKey    = "olm.operatorNamespace"
	OperatorGroupTargetsAnnotationKey      = "olm.targetNamespaces"
	OperatorGroupProvidedAPIsAnnotationKey = "olm.providedAPIs"

	OperatorGroupKind = "OperatorGroup"

	OperatorGroupLabelPrefix   = "olm.operatorgroup.uid/"
	OperatorGroupLabelTemplate = OperatorGroupLabelPrefix + "%s"
)
View Source
const (
	// Upgradeable indicates that the operator is upgradeable
	Upgradeable string = "Upgradeable"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects.
	GroupVersion = schema.GroupVersion{Group: "operators.coreos.com", Version: "v1"}

	// SchemeGroupVersion is required for compatibility with client generation.
	SchemeGroupVersion = GroupVersion

	// 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
)

Functions

func IsOperatorGroupLabel

func IsOperatorGroupLabel(label string) bool

IsOperatorGroupLabel returns true if the label is an OperatorGroup label.

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

Types

type Components

type Components struct {
	// LabelSelector is a label query over a set of resources used to select the operator's components
	LabelSelector *metav1.LabelSelector `json:"labelSelector"`
	// Refs are a set of references to the operator's component resources, selected with LabelSelector.
	// +optional
	Refs []RichReference `json:"refs,omitempty"`
}

Components tracks the resources that compose an operator.

func (*Components) DeepCopy

func (in *Components) DeepCopy() *Components

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Components.

func (*Components) DeepCopyInto

func (in *Components) DeepCopyInto(out *Components)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Condition

type Condition struct {
	// Type of condition.
	Type ConditionType `json:"type"`
	// Status of the condition, one of True, False, Unknown.
	Status corev1.ConditionStatus `json:"status"`
	// The reason for the condition's last transition.
	// +optional
	Reason string `json:"reason,omitempty"`
	// A human readable message indicating details about the transition.
	// +optional
	Message string `json:"message,omitempty"`
	// Last time the condition was probed
	// +optional
	LastUpdateTime *metav1.Time `json:"lastUpdateTime,omitempty"`
	// Last time the condition transitioned from one status to another.
	// +optional
	LastTransitionTime *metav1.Time `json:"lastTransitionTime,omitempty"`
}

Condition represent the latest available observations of an component's state.

func (*Condition) DeepCopy

func (in *Condition) DeepCopy() *Condition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Condition.

func (*Condition) DeepCopyInto

func (in *Condition) DeepCopyInto(out *Condition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ConditionType

type ConditionType string

ConditionType codifies a condition's type.

type Operator

type Operator struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   OperatorSpec   `json:"spec,omitempty"`
	Status OperatorStatus `json:"status,omitempty"`
}

Operator represents a cluster operator.

func (*Operator) DeepCopy

func (in *Operator) DeepCopy() *Operator

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Operator.

func (*Operator) DeepCopyInto

func (in *Operator) DeepCopyInto(out *Operator)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Operator) DeepCopyObject

func (in *Operator) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OperatorCondition added in v0.3.21

type OperatorCondition struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`

	Spec   OperatorConditionSpec   `json:"spec,omitempty"`
	Status OperatorConditionStatus `json:"status,omitempty"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +genclient +kubebuilder:storageversion +kubebuilder:resource:shortName=condition,categories=olm +kubebuilder:subresource:status OperatorCondition is a Custom Resource of type `OperatorCondition` which is used to convey information to OLM about the state of an operator.

func (*OperatorCondition) DeepCopy added in v0.3.21

func (in *OperatorCondition) DeepCopy() *OperatorCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorCondition.

func (*OperatorCondition) DeepCopyInto added in v0.3.21

func (in *OperatorCondition) DeepCopyInto(out *OperatorCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OperatorCondition) DeepCopyObject added in v0.3.21

func (in *OperatorCondition) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OperatorConditionList added in v0.3.21

type OperatorConditionList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []OperatorCondition `json:"items"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object OperatorConditionList represents a list of Conditions.

func (*OperatorConditionList) DeepCopy added in v0.3.21

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorConditionList.

func (*OperatorConditionList) DeepCopyInto added in v0.3.21

func (in *OperatorConditionList) DeepCopyInto(out *OperatorConditionList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OperatorConditionList) DeepCopyObject added in v0.3.21

func (in *OperatorConditionList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OperatorConditionSpec added in v0.3.21

type OperatorConditionSpec struct {
	ServiceAccounts []string           `json:"serviceAccounts,omitempty"`
	Deployments     []string           `json:"deployments,omitempty"`
	Overrides       []metav1.Condition `json:"overrides,omitempty"`
}

OperatorConditionSpec allows a cluster admin to convey information about the state of an operator to OLM, potentially overriding state reported by the operator.

func (*OperatorConditionSpec) DeepCopy added in v0.3.21

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorConditionSpec.

func (*OperatorConditionSpec) DeepCopyInto added in v0.3.21

func (in *OperatorConditionSpec) DeepCopyInto(out *OperatorConditionSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OperatorConditionStatus added in v0.3.21

type OperatorConditionStatus struct {
	Conditions []metav1.Condition `json:"conditions,omitempty"`
}

OperatorConditionStatus allows an operator to convey information its state to OLM. The status may trail the actual state of a system.

func (*OperatorConditionStatus) DeepCopy added in v0.3.21

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorConditionStatus.

func (*OperatorConditionStatus) DeepCopyInto added in v0.3.21

func (in *OperatorConditionStatus) DeepCopyInto(out *OperatorConditionStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OperatorGroup

type OperatorGroup struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`

	// +optional
	Spec   OperatorGroupSpec   `json:"spec"`
	Status OperatorGroupStatus `json:"status,omitempty"`
}

OperatorGroup is the unit of multitenancy for OLM managed operators. It constrains the installation of operators in its namespace to a specified set of target namespaces.

func (*OperatorGroup) BuildTargetNamespaces

func (o *OperatorGroup) BuildTargetNamespaces() string

BuildTargetNamespaces returns the set of target namespaces as a sorted, comma-delimited string

func (*OperatorGroup) DeepCopy

func (in *OperatorGroup) DeepCopy() *OperatorGroup

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorGroup.

func (*OperatorGroup) DeepCopyInto

func (in *OperatorGroup) DeepCopyInto(out *OperatorGroup)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OperatorGroup) DeepCopyObject

func (in *OperatorGroup) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*OperatorGroup) HasServiceAccountSynced

func (o *OperatorGroup) HasServiceAccountSynced() bool

HasServiceAccountSynced returns true if the service account specified has been synced.

func (*OperatorGroup) IsServiceAccountSpecified

func (o *OperatorGroup) IsServiceAccountSpecified() bool

IsServiceAccountSpecified returns true if the spec has a service account name specified.

func (*OperatorGroup) NamespaceLabelSelector

func (o *OperatorGroup) NamespaceLabelSelector() (*metav1.LabelSelector, error)

NamespaceLabelSelector provides a selector that can be used to filter namespaces that belong to the OperatorGroup.

func (*OperatorGroup) OGLabelKeyAndValue

func (o *OperatorGroup) OGLabelKeyAndValue() (string, string, error)

OGLabelKeyAndValue returns a key and value that should be applied to namespaces listed in the OperatorGroup. If the UID is not set an error is returned.

type OperatorGroupList

type OperatorGroupList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`
	// +listType=set
	Items []OperatorGroup `json:"items"`
}

OperatorGroupList is a list of OperatorGroup resources.

func (*OperatorGroupList) DeepCopy

func (in *OperatorGroupList) DeepCopy() *OperatorGroupList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorGroupList.

func (*OperatorGroupList) DeepCopyInto

func (in *OperatorGroupList) DeepCopyInto(out *OperatorGroupList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OperatorGroupList) DeepCopyObject

func (in *OperatorGroupList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OperatorGroupSpec

type OperatorGroupSpec struct {
	// Selector selects the OperatorGroup's target namespaces.
	// +optional
	Selector *metav1.LabelSelector `json:"selector,omitempty"`

	// TargetNamespaces is an explicit set of namespaces to target.
	// If it is set, Selector is ignored.
	// +optional
	// +listType=set
	TargetNamespaces []string `json:"targetNamespaces,omitempty"`

	// ServiceAccountName is the admin specified service account which will be
	// used to deploy operator(s) in this operator group.
	ServiceAccountName string `json:"serviceAccountName,omitempty"`

	// Static tells OLM not to update the OperatorGroup's providedAPIs annotation
	// +optional
	StaticProvidedAPIs bool `json:"staticProvidedAPIs,omitempty"`
}

OperatorGroupSpec is the spec for an OperatorGroup resource.

func (*OperatorGroupSpec) DeepCopy

func (in *OperatorGroupSpec) DeepCopy() *OperatorGroupSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorGroupSpec.

func (*OperatorGroupSpec) DeepCopyInto

func (in *OperatorGroupSpec) DeepCopyInto(out *OperatorGroupSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OperatorGroupStatus

type OperatorGroupStatus struct {
	// Namespaces is the set of target namespaces for the OperatorGroup.
	// +listType=set
	Namespaces []string `json:"namespaces,omitempty"`

	// ServiceAccountRef references the service account object specified.
	ServiceAccountRef *corev1.ObjectReference `json:"serviceAccountRef,omitempty"`

	// LastUpdated is a timestamp of the last time the OperatorGroup's status was Updated.
	LastUpdated *metav1.Time `json:"lastUpdated"`
}

OperatorGroupStatus is the status for an OperatorGroupResource.

func (*OperatorGroupStatus) DeepCopy

func (in *OperatorGroupStatus) DeepCopy() *OperatorGroupStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorGroupStatus.

func (*OperatorGroupStatus) DeepCopyInto

func (in *OperatorGroupStatus) DeepCopyInto(out *OperatorGroupStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OperatorList

type OperatorList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Operator `json:"items"`
}

OperatorList contains a list of Operators.

func (*OperatorList) DeepCopy

func (in *OperatorList) DeepCopy() *OperatorList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorList.

func (*OperatorList) DeepCopyInto

func (in *OperatorList) DeepCopyInto(out *OperatorList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OperatorList) DeepCopyObject

func (in *OperatorList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OperatorSpec

type OperatorSpec struct{}

OperatorSpec defines the desired state of Operator

func (*OperatorSpec) DeepCopy

func (in *OperatorSpec) DeepCopy() *OperatorSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorSpec.

func (*OperatorSpec) DeepCopyInto

func (in *OperatorSpec) DeepCopyInto(out *OperatorSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OperatorStatus

type OperatorStatus struct {
	// Components describes resources that compose the operator.
	// +optional
	Components *Components `json:"components,omitempty"`
}

OperatorStatus defines the observed state of an Operator and its components

func (*OperatorStatus) DeepCopy

func (in *OperatorStatus) DeepCopy() *OperatorStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OperatorStatus.

func (*OperatorStatus) DeepCopyInto

func (in *OperatorStatus) DeepCopyInto(out *OperatorStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RichReference

type RichReference struct {
	*corev1.ObjectReference `json:",inline"`
	// Conditions represents the latest state of the component.
	// +optional
	// +patchMergeKey=type
	// +patchStrategy=merge
	Conditions []Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"`
}

RichReference is a reference to a resource, enriched with its status conditions.

func (*RichReference) DeepCopy

func (in *RichReference) DeepCopy() *RichReference

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RichReference.

func (*RichReference) DeepCopyInto

func (in *RichReference) DeepCopyInto(out *RichReference)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL