api

package
v0.0.0-...-c52bf70 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AdditionalVolume

type AdditionalVolume struct {
	Volume    []corev1.Volume      `json:"volume,omitempty"`
	MountPath []corev1.VolumeMount `json:"mountPath,omitempty"`
}

Additional Volume is provided by user that is mounted on the pods +k8s:deepcopy-gen=true

func (*AdditionalVolume) DeepCopy

func (in *AdditionalVolume) DeepCopy() *AdditionalVolume

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

func (*AdditionalVolume) DeepCopyInto

func (in *AdditionalVolume) DeepCopyInto(out *AdditionalVolume)

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

type ExistingPasswordSecret

type ExistingPasswordSecret struct {
	Name *string `json:"name,omitempty"`
	Key  *string `json:"key,omitempty"`
}

ExistingPasswordSecret is the struct to access the existing secret +k8s:deepcopy-gen=true

func (*ExistingPasswordSecret) DeepCopy

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

func (*ExistingPasswordSecret) DeepCopyInto

func (in *ExistingPasswordSecret) DeepCopyInto(out *ExistingPasswordSecret)

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

type KubernetesConfig

type KubernetesConfig struct {
	Image                  string                           `json:"image"`
	ImagePullPolicy        corev1.PullPolicy                `json:"imagePullPolicy,omitempty"`
	Resources              *corev1.ResourceRequirements     `json:"resources,omitempty"`
	ExistingPasswordSecret *ExistingPasswordSecret          `json:"redisSecret,omitempty"`
	ImagePullSecrets       *[]corev1.LocalObjectReference   `json:"imagePullSecrets,omitempty"`
	UpdateStrategy         appsv1.StatefulSetUpdateStrategy `json:"updateStrategy,omitempty"`
	Service                *ServiceConfig                   `json:"service,omitempty"`
	IgnoreAnnotations      []string                         `json:"ignoreAnnotations,omitempty"`
}

KubernetesConfig will be the JSON struct for Basic Redis Config +k8s:deepcopy-gen=true

func (*KubernetesConfig) DeepCopy

func (in *KubernetesConfig) DeepCopy() *KubernetesConfig

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

func (*KubernetesConfig) DeepCopyInto

func (in *KubernetesConfig) DeepCopyInto(out *KubernetesConfig)

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

type Probe

type Probe struct {
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:default=1
	InitialDelaySeconds int32 `json:"initialDelaySeconds,omitempty" protobuf:"varint,2,opt,name=initialDelaySeconds"`
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:default=1
	TimeoutSeconds int32 `json:"timeoutSeconds,omitempty" protobuf:"varint,3,opt,name=timeoutSeconds"`
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:default=10
	PeriodSeconds int32 `json:"periodSeconds,omitempty" protobuf:"varint,4,opt,name=periodSeconds"`
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:default=1
	SuccessThreshold int32 `json:"successThreshold,omitempty" protobuf:"varint,5,opt,name=successThreshold"`
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:default=3
	FailureThreshold int32 `json:"failureThreshold,omitempty" protobuf:"varint,6,opt,name=failureThreshold"`
}

Probe is a interface for ReadinessProbe and LivenessProbe +k8s:deepcopy-gen=true

func (*Probe) DeepCopy

func (in *Probe) DeepCopy() *Probe

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

func (*Probe) DeepCopyInto

func (in *Probe) DeepCopyInto(out *Probe)

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

type RedisConfig

type RedisConfig struct {
	AdditionalRedisConfig *string `json:"additionalRedisConfig,omitempty"`
}

RedisConfig defines the external configuration of Redis +k8s:deepcopy-gen=true

func (*RedisConfig) DeepCopy

func (in *RedisConfig) DeepCopy() *RedisConfig

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

func (*RedisConfig) DeepCopyInto

func (in *RedisConfig) DeepCopyInto(out *RedisConfig)

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

type RedisExporter

type RedisExporter struct {
	Enabled bool `json:"enabled,omitempty"`
	// +kubebuilder:default:=9121
	Port            *int                         `json:"port,omitempty"`
	Image           string                       `json:"image"`
	Resources       *corev1.ResourceRequirements `json:"resources,omitempty"`
	ImagePullPolicy corev1.PullPolicy            `json:"imagePullPolicy,omitempty"`
	EnvVars         *[]corev1.EnvVar             `json:"env,omitempty"`
}

RedisExporter interface will have the information for redis exporter related stuff +k8s:deepcopy-gen=true

func (*RedisExporter) DeepCopy

func (in *RedisExporter) DeepCopy() *RedisExporter

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

func (*RedisExporter) DeepCopyInto

func (in *RedisExporter) DeepCopyInto(out *RedisExporter)

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

type RedisFollower

type RedisFollower struct {
	Replicas            *int32                    `json:"replicas,omitempty"`
	RedisConfig         *RedisConfig              `json:"redisConfig,omitempty"`
	Affinity            *corev1.Affinity          `json:"affinity,omitempty"`
	PodDisruptionBudget *RedisPodDisruptionBudget `json:"pdb,omitempty"`
	// +kubebuilder:default:={initialDelaySeconds: 1, timeoutSeconds: 1, periodSeconds: 10, successThreshold: 1, failureThreshold:3}
	ReadinessProbe *Probe `json:"readinessProbe,omitempty" protobuf:"bytes,11,opt,name=readinessProbe"`
	// +kubebuilder:default:={initialDelaySeconds: 1, timeoutSeconds: 1, periodSeconds: 10, successThreshold: 1, failureThreshold:3}
	LivenessProbe *Probe               `json:"livenessProbe,omitempty" protobuf:"bytes,11,opt,name=livenessProbe"`
	Tolerations   *[]corev1.Toleration `json:"tolerations,omitempty"`
	NodeSelector  map[string]string    `json:"nodeSelector,omitempty"`
}

RedisFollower interface will have the redis follower configuration +k8s:deepcopy-gen=true

func (*RedisFollower) DeepCopy

func (in *RedisFollower) DeepCopy() *RedisFollower

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

func (*RedisFollower) DeepCopyInto

func (in *RedisFollower) DeepCopyInto(out *RedisFollower)

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

type RedisLeader

type RedisLeader struct {
	Replicas            *int32                    `json:"replicas,omitempty"`
	RedisConfig         *RedisConfig              `json:"redisConfig,omitempty"`
	Affinity            *corev1.Affinity          `json:"affinity,omitempty"`
	PodDisruptionBudget *RedisPodDisruptionBudget `json:"pdb,omitempty"`
	// +kubebuilder:default:={initialDelaySeconds: 1, timeoutSeconds: 1, periodSeconds: 10, successThreshold: 1, failureThreshold:3}
	ReadinessProbe *Probe `json:"readinessProbe,omitempty" protobuf:"bytes,11,opt,name=readinessProbe"`
	// +kubebuilder:default:={initialDelaySeconds: 1, timeoutSeconds: 1, periodSeconds: 10, successThreshold: 1, failureThreshold:3}
	LivenessProbe *Probe               `json:"livenessProbe,omitempty" protobuf:"bytes,11,opt,name=livenessProbe"`
	Tolerations   *[]corev1.Toleration `json:"tolerations,omitempty"`
	NodeSelector  map[string]string    `json:"nodeSelector,omitempty"`
}

RedisLeader interface will have the redis leader configuration +k8s:deepcopy-gen=true

func (*RedisLeader) DeepCopy

func (in *RedisLeader) DeepCopy() *RedisLeader

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

func (*RedisLeader) DeepCopyInto

func (in *RedisLeader) DeepCopyInto(out *RedisLeader)

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

type RedisPodDisruptionBudget

type RedisPodDisruptionBudget struct {
	Enabled        bool   `json:"enabled,omitempty"`
	MinAvailable   *int32 `json:"minAvailable,omitempty"`
	MaxUnavailable *int32 `json:"maxUnavailable,omitempty"`
}

RedisPodDisruptionBudget configure a PodDisruptionBudget on the resource (leader/follower) +k8s:deepcopy-gen=true

func (*RedisPodDisruptionBudget) DeepCopy

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

func (*RedisPodDisruptionBudget) DeepCopyInto

func (in *RedisPodDisruptionBudget) DeepCopyInto(out *RedisPodDisruptionBudget)

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

type RedisSentinelConfig

type RedisSentinelConfig struct {
	AdditionalSentinelConfig *string              `json:"additionalSentinelConfig,omitempty"`
	RedisReplicationName     string               `json:"redisReplicationName"`
	RedisReplicationPassword *corev1.EnvVarSource `json:"redisReplicationPassword,omitempty"`
	// +kubebuilder:default:=myMaster
	MasterGroupName string `json:"masterGroupName,omitempty"`
	// +kubebuilder:default:="6379"
	RedisPort string `json:"redisPort,omitempty"`
	// +kubebuilder:default:="2"
	Quorum string `json:"quorum,omitempty"`
	// +kubebuilder:default:="1"
	ParallelSyncs string `json:"parallelSyncs,omitempty"`
	// +kubebuilder:default:="180000"
	FailoverTimeout string `json:"failoverTimeout,omitempty"`
	// +kubebuilder:default:="30000"
	DownAfterMilliseconds string `json:"downAfterMilliseconds,omitempty"`
}

+k8s:deepcopy-gen=true

func (*RedisSentinelConfig) DeepCopy

func (in *RedisSentinelConfig) DeepCopy() *RedisSentinelConfig

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

func (*RedisSentinelConfig) DeepCopyInto

func (in *RedisSentinelConfig) DeepCopyInto(out *RedisSentinelConfig)

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

type ServiceConfig

type ServiceConfig struct {
	// +kubebuilder:validation:Enum=LoadBalancer;NodePort;ClusterIP
	ServiceType        string            `json:"serviceType,omitempty"`
	ServiceAnnotations map[string]string `json:"annotations,omitempty"`
}

ServiceConfig define the type of service to be created and its annotations +k8s:deepcopy-gen=true

func (*ServiceConfig) DeepCopy

func (in *ServiceConfig) DeepCopy() *ServiceConfig

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

func (*ServiceConfig) DeepCopyInto

func (in *ServiceConfig) DeepCopyInto(out *ServiceConfig)

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

type Sidecar

type Sidecar struct {
	Name            string                       `json:"name"`
	Image           string                       `json:"image"`
	ImagePullPolicy corev1.PullPolicy            `json:"imagePullPolicy,omitempty"`
	Resources       *corev1.ResourceRequirements `json:"resources,omitempty"`
	EnvVars         *[]corev1.EnvVar             `json:"env,omitempty"`
}

Sidecar for each Redis pods +k8s:deepcopy-gen=true

func (*Sidecar) DeepCopy

func (in *Sidecar) DeepCopy() *Sidecar

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

func (*Sidecar) DeepCopyInto

func (in *Sidecar) DeepCopyInto(out *Sidecar)

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

type Storage

type Storage struct {
	KeepAfterDelete     bool                         `json:"keepAfterDelete,omitempty"`
	VolumeClaimTemplate corev1.PersistentVolumeClaim `json:"volumeClaimTemplate,omitempty"`
	VolumeMount         AdditionalVolume             `json:"volumeMount,omitempty"`
}

Storage is the inteface to add pvc and pv support in redis +k8s:deepcopy-gen=true

func (*Storage) DeepCopy

func (in *Storage) DeepCopy() *Storage

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

func (*Storage) DeepCopyInto

func (in *Storage) DeepCopyInto(out *Storage)

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

type TLSConfig

type TLSConfig struct {
	CaKeyFile   string `json:"ca,omitempty"`
	CertKeyFile string `json:"cert,omitempty"`
	KeyFile     string `json:"key,omitempty"`
	// Reference to secret which contains the certificates
	Secret corev1.SecretVolumeSource `json:"secret"`
}

TLS Configuration for redis instances +k8s:deepcopy-gen=true

func (*TLSConfig) DeepCopy

func (in *TLSConfig) DeepCopy() *TLSConfig

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

func (*TLSConfig) DeepCopyInto

func (in *TLSConfig) DeepCopyInto(out *TLSConfig)

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

Directories

Path Synopsis
Package v1beta1 contains API Schema definitions for the redis v1beta1 API group +kubebuilder:object:generate=true +groupName=redis.redis.opstreelabs.in
Package v1beta1 contains API Schema definitions for the redis v1beta1 API group +kubebuilder:object:generate=true +groupName=redis.redis.opstreelabs.in
Package v1beta2 contains API Schema definitions for the redis v1beta2 API group +kubebuilder:object:generate=true +groupName=redis.redis.opstreelabs.in
Package v1beta2 contains API Schema definitions for the redis v1beta2 API group +kubebuilder:object:generate=true +groupName=redis.redis.opstreelabs.in

Jump to

Keyboard shortcuts

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