v1alpha1

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2022 License: Apache-2.0 Imports: 6 Imported by: 7

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: objectstorage.GroupName, Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

Types

type AuthenticationType

type AuthenticationType string
const (
	AuthenticationTypeKey AuthenticationType = "Key"
	AuthenticationTypeIAM AuthenticationType = "IAM"
)

type Bucket

type Bucket struct {
	metav1.TypeMeta `json:",inline"`

	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec BucketSpec `json:"spec,omitempty"`

	// +optional
	Status BucketStatus `json:"status,omitempty"`
}

+genclient +genclient:nonNamespaced +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:resource:scope=Cluster +kubebuilder:storageversion +kubebuilder:subresource:status

func (*Bucket) DeepCopy

func (in *Bucket) DeepCopy() *Bucket

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

func (*Bucket) DeepCopyInto

func (in *Bucket) DeepCopyInto(out *Bucket)

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

func (*Bucket) DeepCopyObject

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

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

type BucketAccess

type BucketAccess struct {
	metav1.TypeMeta `json:",inline"`

	// +optional
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec BucketAccessSpec `json:"spec,omitempty"`

	// +optional
	Status BucketAccessStatus `json:"status"`
}

+genclient +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:resource:scope=Namespaced +kubebuilder:storageversion +kubebuilder:subresource:status

func (*BucketAccess) DeepCopy

func (in *BucketAccess) DeepCopy() *BucketAccess

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

func (*BucketAccess) DeepCopyInto

func (in *BucketAccess) DeepCopyInto(out *BucketAccess)

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

func (*BucketAccess) DeepCopyObject

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

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

type BucketAccessClass

type BucketAccessClass struct {
	metav1.TypeMeta `json:",inline"`

	// +optional
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// DriverName is the name of driver associated with
	// this BucketAccess
	DriverName string `json:"driverName"`

	// AuthenticationType denotes the style of authentication
	// It can be one of
	// KEY - access, secret tokens based authentication
	// IAM - implicit authentication of pods to the OSP based on service account mappings
	AuthenticationType AuthenticationType `json:"authenticationType"`

	// Parameters is an opaque map for passing in configuration to a driver
	// for granting access to a bucket
	// +optional
	Parameters map[string]string `json:"parameters,omitempty"`
}

+genclient +genclient:nonNamespaced +genclient:noStatus +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:resource:scope=Cluster +kubebuilder:storageversion

func (*BucketAccessClass) DeepCopy

func (in *BucketAccessClass) DeepCopy() *BucketAccessClass

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

func (*BucketAccessClass) DeepCopyInto

func (in *BucketAccessClass) DeepCopyInto(out *BucketAccessClass)

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

func (*BucketAccessClass) DeepCopyObject

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

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

type BucketAccessClassList

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

func (*BucketAccessClassList) DeepCopy

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

func (*BucketAccessClassList) DeepCopyInto

func (in *BucketAccessClassList) DeepCopyInto(out *BucketAccessClassList)

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

func (*BucketAccessClassList) DeepCopyObject

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

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

type BucketAccessList

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

func (*BucketAccessList) DeepCopy

func (in *BucketAccessList) DeepCopy() *BucketAccessList

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

func (*BucketAccessList) DeepCopyInto

func (in *BucketAccessList) DeepCopyInto(out *BucketAccessList)

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

func (*BucketAccessList) DeepCopyObject

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

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

type BucketAccessSpec

type BucketAccessSpec struct {
	// BucketClaimName is the name of the BucketClaim.
	BucketClaimName string `json:"bucketClaimName"`

	// Protocol is the name of the Protocol
	// that this access credential is supposed to support
	// If left empty, it will choose the protocol supported
	// by the bucket. If the bucket supports multiple protocols,
	// the end protocol is determined by the driver.
	// +optional
	Protocol Protocol `json:"protocol,omitempty"`

	// BucketAccessClassName is the name of the BucketAccessClass
	BucketAccessClassName string `json:"bucketAccessClassName"`

	// CredentialsSecretName is the name of the secret that COSI should populate
	// with the credentials. If a secret by this name already exists, then it is
	// assumed that credentials have already been generated. It is not overridden.
	// This secret is deleted when the BucketAccess is delted.
	CredentialsSecretName string `json:"credentialsSecretName"`

	// ServiceAccountName is the name of the serviceAccount that COSI will map
	// to the OSP service account when IAM styled authentication is specified
	// +optional
	ServiceAccountName string `json:"serviceAccountName,omitempty"`
}

func (*BucketAccessSpec) DeepCopy

func (in *BucketAccessSpec) DeepCopy() *BucketAccessSpec

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

func (*BucketAccessSpec) DeepCopyInto

func (in *BucketAccessSpec) DeepCopyInto(out *BucketAccessSpec)

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

type BucketAccessStatus

type BucketAccessStatus struct {
	// AccountID is the unique ID for the account in the OSP. It will be populated
	// by the COSI sidecar once access has been successfully granted.
	// +optional
	AccountID string `json:"accountID,omitempty"`

	// AccessGranted indicates the successful grant of privileges to access the bucket
	// +optional
	AccessGranted bool `json:"accessGranted"`
}

func (*BucketAccessStatus) DeepCopy

func (in *BucketAccessStatus) DeepCopy() *BucketAccessStatus

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

func (*BucketAccessStatus) DeepCopyInto

func (in *BucketAccessStatus) DeepCopyInto(out *BucketAccessStatus)

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

type BucketClaim

type BucketClaim struct {
	metav1.TypeMeta `json:",inline"`

	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec BucketClaimSpec `json:"spec,omitempty"`

	// +optional
	Status BucketClaimStatus `json:"status,omitempty"`
}

+genclient +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:resource:scope=Namespaced +kubebuilder:subresource:status +kubebuilder:storageversion

func (*BucketClaim) DeepCopy

func (in *BucketClaim) DeepCopy() *BucketClaim

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

func (*BucketClaim) DeepCopyInto

func (in *BucketClaim) DeepCopyInto(out *BucketClaim)

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

func (*BucketClaim) DeepCopyObject

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

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

type BucketClaimList

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

func (*BucketClaimList) DeepCopy

func (in *BucketClaimList) DeepCopy() *BucketClaimList

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

func (*BucketClaimList) DeepCopyInto

func (in *BucketClaimList) DeepCopyInto(out *BucketClaimList)

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

func (*BucketClaimList) DeepCopyObject

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

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

type BucketClaimSpec

type BucketClaimSpec struct {
	// Name of the BucketClass
	BucketClassName string `json:"bucketClassName,omitempty"`

	// Protocols are the set of data API this bucket is required to support.
	// The possible values for protocol are:
	// -  S3: Indicates Amazon S3 protocol
	// -  Azure: Indicates Microsoft Azure BlobStore protocol
	// -  GCS: Indicates Google Cloud Storage protocol
	Protocols []Protocol `json:"protocols"`

	// Name of a bucket object that was manually
	// created to import a bucket created outside of COSI
	// If unspecified, then a new Bucket will be dynamically provisioned
	// +optional
	ExistingBucketName string `json:"existingBucketName,omitempty"`
}

func (*BucketClaimSpec) DeepCopy

func (in *BucketClaimSpec) DeepCopy() *BucketClaimSpec

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

func (*BucketClaimSpec) DeepCopyInto

func (in *BucketClaimSpec) DeepCopyInto(out *BucketClaimSpec)

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

type BucketClaimStatus

type BucketClaimStatus struct {
	// BucketReady indicates that the bucket is ready for consumpotion
	// by workloads
	BucketReady bool `json:"bucketReady"`

	// BucketName is the name of the provisioned Bucket in response
	// to this BucketClaim. It is generated and set by the COSI controller
	// before making the creation request to the OSP backend.
	// +optional
	BucketName string `json:"bucketName,omitempty"`
}

func (*BucketClaimStatus) DeepCopy

func (in *BucketClaimStatus) DeepCopy() *BucketClaimStatus

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

func (*BucketClaimStatus) DeepCopyInto

func (in *BucketClaimStatus) DeepCopyInto(out *BucketClaimStatus)

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

type BucketClass

type BucketClass struct {
	metav1.TypeMeta `json:",inline"`

	// +optional
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// DriverName is the name of driver associated with this bucket
	DriverName string `json:"driverName"`

	// DeletionPolicy is used to specify how COSI should handle deletion of this
	// bucket. There are 2 possible values:
	//  - Retain: Indicates that the bucket should not be deleted from the OSP
	//  - Delete: Indicates that the bucket should be deleted from the OSP
	//        once all the workloads accessing this bucket are done
	// +kubebuilder:default:=retain
	DeletionPolicy DeletionPolicy `json:"deletionPolicy"`

	// Parameters is an opaque map for passing in configuration to a driver
	// for creating the bucket
	// +optional
	Parameters map[string]string `json:"parameters,omitempty"`
}

+genclient +genclient:nonNamespaced +genclient:noStatus +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:resource:scope=Cluster +kubebuilder:storageversion

func (*BucketClass) DeepCopy

func (in *BucketClass) DeepCopy() *BucketClass

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

func (*BucketClass) DeepCopyInto

func (in *BucketClass) DeepCopyInto(out *BucketClass)

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

func (*BucketClass) DeepCopyObject

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

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

type BucketClassList

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

func (*BucketClassList) DeepCopy

func (in *BucketClassList) DeepCopy() *BucketClassList

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

func (*BucketClassList) DeepCopyInto

func (in *BucketClassList) DeepCopyInto(out *BucketClassList)

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

func (*BucketClassList) DeepCopyObject

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

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

type BucketList

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

func (*BucketList) DeepCopy

func (in *BucketList) DeepCopy() *BucketList

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

func (*BucketList) DeepCopyInto

func (in *BucketList) DeepCopyInto(out *BucketList)

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

func (*BucketList) DeepCopyObject

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

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

type BucketSpec

type BucketSpec struct {
	// DriverName is the name of driver associated with this bucket
	DriverName string `json:"driverName"`

	// Name of the BucketClass specified in the BucketRequest
	BucketClassName string `json:"bucketClassName"`

	// Name of the BucketClaim that resulted in the creation of this Bucket
	// In case the Bucket object was created manually, then this should refer
	// to the BucketClaim with which this Bucket should be bound
	BucketClaim *corev1.ObjectReference `json:"bucketClaim"`

	// Protocols are the set of data APIs this bucket is expected to support.
	// The possible values for protocol are:
	// -  S3: Indicates Amazon S3 protocol
	// -  Azure: Indicates Microsoft Azure BlobStore protocol
	// -  GCS: Indicates Google Cloud Storage protocol
	Protocols []Protocol `json:"protocols"`

	// +optional
	Parameters map[string]string `json:"parameters,omitempty"`

	// DeletionPolicy is used to specify how COSI should handle deletion of this
	// bucket. There are 2 possible values:
	//  - Retain: Indicates that the bucket should not be deleted from the OSP (default)
	//  - Delete: Indicates that the bucket should be deleted from the OSP
	//        once all the workloads accessing this bucket are done
	// +optional
	// +kubebuilder:default:=retain
	DeletionPolicy DeletionPolicy `json:"deletionPolicy"`

	// ExistingBucketID is the unique id of the bucket in the OSP. This field should be
	// used to specify a bucket that has been created outside of COSI.
	// This field will be empty when the Bucket is dynamically provisioned by COSI.
	// +optional
	ExistingBucketID string `json:"existingBucketID,omitempty"`
}

func (*BucketSpec) DeepCopy

func (in *BucketSpec) DeepCopy() *BucketSpec

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

func (*BucketSpec) DeepCopyInto

func (in *BucketSpec) DeepCopyInto(out *BucketSpec)

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

type BucketStatus

type BucketStatus struct {
	// BucketReady is a boolean condition to reflect the successful creation
	// of a bucket.
	BucketReady bool `json:"bucketReady,omitempty"`

	// BucketID is the unique id of the bucket in the OSP. This field will be
	// populated by COSI.
	// +optional
	BucketID string `json:"bucketID,omitempty"`
}

func (*BucketStatus) DeepCopy

func (in *BucketStatus) DeepCopy() *BucketStatus

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

func (*BucketStatus) DeepCopyInto

func (in *BucketStatus) DeepCopyInto(out *BucketStatus)

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

type DeletionPolicy

type DeletionPolicy string
const (
	DeletionPolicyRetain DeletionPolicy = "Retain"
	DeletionPolicyDelete DeletionPolicy = "Delete"
)

type Protocol

type Protocol string
const (
	ProtocolS3    Protocol = "S3"
	ProtocolAzure Protocol = "Azure"
	ProtocolGCP   Protocol = "GCP"
)

Jump to

Keyboard shortcuts

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