v1

package
v0.0.0-...-acbeb8e Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package v1 contains API Schema definitions for the csi v1 API group +kubebuilder:object:generate=true +groupName=csi.ibm.com

Index

Constants

This section is empty.

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "csi.ibm.com", 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
)

Functions

This section is empty.

Types

type CSICluster

type CSICluster struct {

	// cacert is the name of the configMap storing GUI certificates. Mandatory if secureSslMode is true.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="CA Certificate Resource Name",xDescriptors="urn:alm:descriptor:io.kubernetes:ConfigMap"
	Cacert string `json:"cacert,omitempty"` // TODO: Rename to CACert or caCert

	// id is the cluster ID of the Spectrum Scale cluster.
	// +kubebuilder:validation:MaxLength:=20
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Cluster ID",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	Id string `json:"id"` // TODO: Rename to ID or id

	// +optional
	// primary is the primary file system for the Spectrum Scale cluster.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Primary",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	Primary CSIFilesystem `json:"primary"`

	// restApi is a collection of targets for REST calls
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="REST API",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	RestApi []RestApi `json:"restApi"` // TODO: Rename to RESTApi or restApi

	// secret is the name of the basic-auth secret containing credentials to connect to IBM Spectrum Scale REST API server.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Secrets",xDescriptors="urn:alm:descriptor:io.kubernetes:Secret"
	Secrets string `json:"secrets"` // TODO: Secrets should be Singular

	// secureSslMode specifies if a secure SSL connection to connect to Spectrum Scale cluster is required.
	// +kubebuilder:default:=false
	// +kubebuilder:validation:Enum:=true;false
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Secure SSL Mode",xDescriptors="urn:alm:descriptor:com.tectonic.ui:booleanSwitch"
	SecureSslMode bool `json:"secureSslMode"`
}

Defines the fields of a Spectrum Scale cluster specification

func (*CSICluster) DeepCopy

func (in *CSICluster) DeepCopy() *CSICluster

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

func (*CSICluster) DeepCopyInto

func (in *CSICluster) DeepCopyInto(out *CSICluster)

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

type CSIFilesystem

type CSIFilesystem struct {

	// +optional
	// +kubebuilder:default:="1M"
	// Inode limit for Primary Fileset
	InodeLimit string `json:"inodeLimit"`

	// The name of the primary CSIFilesystem
	PrimaryFs string `json:"primaryFs"`

	// +optional
	// +kubebuilder:default:=spectrum-scale-csi-volume-store
	// The name of the primary fileset, created in primaryFs
	PrimaryFset string `json:"primaryFset"`

	// Remote Spectrum Scale cluster ID
	RemoteCluster string `json:"remoteCluster,omitempty"`
}

Defines the fields for CSI for Spectrum Scale file system

func (*CSIFilesystem) DeepCopy

func (in *CSIFilesystem) DeepCopy() *CSIFilesystem

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

func (*CSIFilesystem) DeepCopyInto

func (in *CSIFilesystem) DeepCopyInto(out *CSIFilesystem)

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

type CSINodeSelector

type CSINodeSelector struct {

	// Key for node selector
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Key",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	Key string `json:"key"`

	// Value for key
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Value",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	Value string `json:"value"`
}

CSINodeSelector defines the fields of Node Selector

func (*CSINodeSelector) DeepCopy

func (in *CSINodeSelector) DeepCopy() *CSINodeSelector

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

func (*CSINodeSelector) DeepCopyInto

func (in *CSINodeSelector) DeepCopyInto(out *CSINodeSelector)

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

type CSIReason

type CSIReason string
const (
	CSIConfigured       CSIReason = "Successful"
	CSINotConfigured    CSIReason = "CSIError"
	ResourceSyncError   CSIReason = "SyncError"
	ResourceCreateError CSIReason = "CreateError"
	ResourceReadError   CSIReason = "ReadError"
	ResourceUpdateError CSIReason = "UpdateError"
	Unknown             CSIReason = "Unknown"
)

type CSIScaleOperator

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

	Spec   CSIScaleOperatorSpec   `json:"spec,omitempty"`
	Status CSIScaleOperatorStatus `json:"status,omitempty"`
}

CSIScaleOperator is the Schema for the csiscaleoperators API +operator-sdk:csv:customresourcedefinitions:displayName="IBM CSI Spectrum Scale Driver",resources={{StatefulSet,v1beta2},{DaemonSet,v1beta2},{Pod,v1},{ConfigMap,v1}}

func (*CSIScaleOperator) DeepCopy

func (in *CSIScaleOperator) DeepCopy() *CSIScaleOperator

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

func (*CSIScaleOperator) DeepCopyInto

func (in *CSIScaleOperator) DeepCopyInto(out *CSIScaleOperator)

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

func (*CSIScaleOperator) DeepCopyObject

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

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

type CSIScaleOperatorList

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

CSIScaleOperatorList contains a list of CSIScaleOperator

func (*CSIScaleOperatorList) DeepCopy

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

func (*CSIScaleOperatorList) DeepCopyInto

func (in *CSIScaleOperatorList) DeepCopyInto(out *CSIScaleOperatorList)

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

func (*CSIScaleOperatorList) DeepCopyObject

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

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

type CSIScaleOperatorSpec

type CSIScaleOperatorSpec struct {

	// attacher is the attacher sidecar image for CSI (actually attaches to the storage).
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Attacher Image",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	Attacher string `json:"attacher,omitempty"`

	// attacherNodeSelector is the node selector for attacher sidecar.
	// +kubebuilder:default:={{key:scale,value:`true`}}
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Attacher Node Selector",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	AttacherNodeSelector []CSINodeSelector `json:"attacherNodeSelector,omitempty"`

	// clusters is a collection of Spectrum Scale cluster properties for the CSI driver to mount.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Clusters"
	Clusters []CSICluster `json:"clusters"`

	// driverRegistrar is the Sidecar container image for the CSI Spectrum Scale plugin pods.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Driver Registrar",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	DriverRegistrar string `json:"driverRegistrar,omitempty"`

	// nodeMapping specifies mapping of K8s node with Spectrum Scale node.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Node Mapping",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	NodeMapping []NodeMapping `json:"nodeMapping,omitempty"`

	// pluginNodeSelector is the node selector for Spectrum Scale CSI plugin.
	// +kubebuilder:default:={{key:scale,value:`true`}}
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Plugin Node Selector",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	PluginNodeSelector []CSINodeSelector `json:"pluginNodeSelector,omitempty"`

	// provisioner is the provisioner sidecar image for CSI (actually issues provision requests).
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Provisioner Image",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	Provisioner string `json:"provisioner,omitempty"`

	// provisionerNodeSelector is the node selector for provisioner sidecar.
	// +kubebuilder:default:={{key:scale,value:`true`}}
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Provisioner Node Selector",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	ProvisionerNodeSelector []CSINodeSelector `json:"provisionerNodeSelector,omitempty"`

	// snapshotter is the snapshotter sidecar image for CSI (issues volume snapshot requests).
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Snapshotter Image",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	Snapshotter string `json:"snapshotter,omitempty"`

	// snapshotterNodeSelector is the snapshotter node selector for snapshotter sidecar.
	// +kubebuilder:default:={{key:scale,value:`true`}}
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Snapshotter Node Selector",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	SnapshotterNodeSelector []CSINodeSelector `json:"snapshotterNodeSelector,omitempty"`

	// resizer is the resizer sidecar image for CSI (issues volume expansion requests).
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Resizer Image",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	Resizer string `json:"resizer,omitempty"`

	// resizerNodeSelector is the node selector for resizer sidecar.
	// +kubebuilder:default:={{key:scale,value:`true`}}
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Resizer Node Selector",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	ResizerNodeSelector []CSINodeSelector `json:"resizerNodeSelector,omitempty"`

	// livenessprobe is the image for livenessProbe container (liveness probe is used to know when to restart a container).
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="LivenessProbe",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	LivenessProbe string `json:"livenessprobe,omitempty"`

	// spectrumScale is the image name for the CSI Spectrum Scale node driver plugin container.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Spectrum Scale Image",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	SpectrumScale string `json:"spectrumScale,omitempty"`

	// A passthrough option that distributes an imagePullSecrets array to the
	// containers generated by the CSI scale operator. Please refer to official
	// k8s documentation for your environment for more details.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Image Pull Secrets",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:label","urn:alm:descriptor:com.tectonic.ui:advanced"}
	ImagePullSecrets []string `json:"imagePullSecrets,omitempty"`

	// Array of tolerations that will be distributed to CSI pods. Please refer to
	// official k8s documentation for your environment for more details.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Tolerations",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	Tolerations []corev1.Toleration `json:"tolerations,omitempty"`

	// affinity is a group of affinity scheduling rules.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Affinity",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	Affinity *corev1.Affinity `json:"affinity,omitempty"`

	// +kubebuilder:default:=/var/lib/kubelet
	// kubeletRootDirPath is the path for kubelet root directory.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Kubelet Root Directory Path",xDescriptors="urn:alm:descriptor:com.tectonic.ui:advanced"
	KubeletRootDirPath string `json:"kubeletRootDirPath,omitempty"`

	// PodSecurityPolicy name for CSI driver and sidecar pods.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="CSI Pod Security Policy Name",xDescriptors="urn:alm:descriptor:com.tectonic.ui:hidden"
	CSIpspname string `json:"csipspname,omitempty"`
}

CSIScaleOperatorSpec specifies the desired state of CSI

func (*CSIScaleOperatorSpec) DeepCopy

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

func (*CSIScaleOperatorSpec) DeepCopyInto

func (in *CSIScaleOperatorSpec) DeepCopyInto(out *CSIScaleOperatorSpec)

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

type CSIScaleOperatorStatus

type CSIScaleOperatorStatus struct {

	// version is the current CSIDriver version installed by the operator.
	Version string `json:"version,omitempty"`

	// conditions contains the details for one aspect of the current state of this custom resource.
	//+operator-sdk:csv:customresourcedefinitions:type=status,displayName="Conditions",xDescriptors="urn:alm:descriptor:io.kubernetes.conditions"
	Conditions []metav1.Condition `json:"condition,omitempty"`
}

CSIScaleOperatorStatus defines the observed state of CSIScaleOperator

func (*CSIScaleOperatorStatus) DeepCopy

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

func (*CSIScaleOperatorStatus) DeepCopyInto

func (in *CSIScaleOperatorStatus) DeepCopyInto(out *CSIScaleOperatorStatus)

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

type NodeMapping

type NodeMapping struct {

	// k8sNode is the name of the kubernetes node
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Kubernetes Node",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	K8sNode string `json:"k8sNode"`

	// spectrumscaleNode is the name of the SpectrumScale node
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Spectrum Scale Node",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	SpectrumscaleNode string `json:"spectrumscaleNode"`
}

Defines mapping between kubernetes node and spectrumscale nodes

func (*NodeMapping) DeepCopy

func (in *NodeMapping) DeepCopy() *NodeMapping

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

func (*NodeMapping) DeepCopyInto

func (in *NodeMapping) DeepCopyInto(out *NodeMapping)

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

type RestApi

type RestApi struct {

	// guiHost is the hostname/IP of the Spectrum Scale GUI node.
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="GUI Host",xDescriptors="urn:alm:descriptor:com.tectonic.ui:label"
	GuiHost string `json:"guiHost"`

	// guiPort is the port number of the Spectrum Scale GUI node.
	// +kubebuilder:default:=443
	//+operator-sdk:csv:customresourcedefinitions:type=spec,displayName="GUI Port",xDescriptors="urn:alm:descriptor:com.tectonic.ui:number"
	GuiPort int `json:"guiPort,omitempty"`
}

Defines the fields for REST API server information.

func (*RestApi) DeepCopy

func (in *RestApi) DeepCopy() *RestApi

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

func (*RestApi) DeepCopyInto

func (in *RestApi) DeepCopyInto(out *RestApi)

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