v1beta1

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2023 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Overview

Package v1beta1 contains API Schema definitions for the redis v1beta1 API group +kubebuilder:object:generate=true +groupName=redis.openstack.org

Index

Constants

View Source
const (

	// RedisContainerImage is the fall-back container image for Redis
	RedisContainerImage = "registry.redhat.io/rhel9/redis-6:latest"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "redis.openstack.org", Version: "v1beta1"}

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

func SetupDefaults()

SetupDefaults - initializes any CRD field defaults based on environment variables (the defaulting mechanism itself is implemented via webhooks)

func SetupRedisDefaults

func SetupRedisDefaults(defaults RedisDefaults)

SetupRedisDefaults - initialize Redis spec defaults for use with either internal or external webhooks

Types

type Redis

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

	Spec   RedisSpec   `json:"spec,omitempty"`
	Status RedisStatus `json:"status,omitempty"`
}

Redis is the Schema for the redises API

func (*Redis) DeepCopy

func (in *Redis) DeepCopy() *Redis

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

func (*Redis) DeepCopyInto

func (in *Redis) DeepCopyInto(out *Redis)

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

func (*Redis) DeepCopyObject

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

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

func (*Redis) Default

func (r *Redis) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (Redis) IsReady

func (instance Redis) IsReady() bool

IsReady - returns true if service is ready to serve requests

func (Redis) RbacConditionsSet

func (instance Redis) RbacConditionsSet(c *condition.Condition)

RbacConditionsSet - set the conditions for the rbac object

func (Redis) RbacNamespace

func (instance Redis) RbacNamespace() string

RbacNamespace - return the namespace

func (Redis) RbacResourceName

func (instance Redis) RbacResourceName() string

RbacResourceName - return the name to be used for rbac objects (serviceaccount, role, rolebinding)

func (*Redis) SetupWebhookWithManager

func (r *Redis) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager sets up the webhook with the Manager

func (*Redis) ValidateCreate

func (r *Redis) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*Redis) ValidateDelete

func (r *Redis) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*Redis) ValidateUpdate

func (r *Redis) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type RedisDefaults

type RedisDefaults struct {
	ContainerImageURL string
}

RedisDefaults -

func (*RedisDefaults) DeepCopy

func (in *RedisDefaults) DeepCopy() *RedisDefaults

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

func (*RedisDefaults) DeepCopyInto

func (in *RedisDefaults) DeepCopyInto(out *RedisDefaults)

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

type RedisList

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

RedisList contains a list of Redis

func (*RedisList) DeepCopy

func (in *RedisList) DeepCopy() *RedisList

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

func (*RedisList) DeepCopyInto

func (in *RedisList) DeepCopyInto(out *RedisList)

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

func (*RedisList) DeepCopyObject

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

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

type RedisSpec

type RedisSpec struct {
	// +kubebuilder:validation:Required
	// Name of the redis container image to run (will be set to environmental default if empty)
	ContainerImage string `json:"containerImage"`

	// +kubebuilder:validation:Optional
	// +kubebuilder:default=1
	// Size of the redis cluster
	Replicas *int32 `json:"replicas"`
}

RedisSpec defines the desired state of Redis

func (*RedisSpec) DeepCopy

func (in *RedisSpec) DeepCopy() *RedisSpec

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

func (*RedisSpec) DeepCopyInto

func (in *RedisSpec) DeepCopyInto(out *RedisSpec)

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

func (*RedisSpec) Default

func (spec *RedisSpec) Default()

Default - set defaults for this Redis spec

type RedisStatus

type RedisStatus struct {
	// Conditions
	Conditions condition.Conditions `json:"conditions,omitempty" optional:"true"`
}

RedisStatus defines the observed state of Redis

func (*RedisStatus) DeepCopy

func (in *RedisStatus) DeepCopy() *RedisStatus

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

func (*RedisStatus) DeepCopyInto

func (in *RedisStatus) DeepCopyInto(out *RedisStatus)

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