v1alpha1

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the v1alpha1 API group +kubebuilder:object:generate=true +groupName=valkey.buf.red

Index

Constants

This section is empty.

Variables

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

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

type AccountType string
const (
	SystemAccount AccountType = "system"
	CustomAccount AccountType = "custom"
)

type Authorization

type Authorization struct {
	// Username the username for valkey
	Username string `json:"username,omitempty"`
	// PasswordSecret the password secret for valkey
	PasswordSecret string `json:"passwordSecret,omitempty"`
	// TLSSecret the tls secret
	TLSSecret string `json:"tlsSecret,omitempty"`
}

Authorization defines the authorization settings for valkey

func (*Authorization) DeepCopy

func (in *Authorization) DeepCopy() *Authorization

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

func (*Authorization) DeepCopyInto

func (in *Authorization) DeepCopyInto(out *Authorization)

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

type Cluster

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

	Spec   ClusterSpec   `json:"spec,omitempty"`
	Status ClusterStatus `json:"status,omitempty"`
}

Cluster is the Schema for the clusters API

func (*Cluster) DeepCopy

func (in *Cluster) DeepCopy() *Cluster

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

func (*Cluster) DeepCopyInto

func (in *Cluster) DeepCopyInto(out *Cluster)

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

func (*Cluster) DeepCopyObject

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

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

type ClusterList

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

ClusterList contains a list of Cluster

func (*ClusterList) DeepCopy

func (in *ClusterList) DeepCopy() *ClusterList

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

func (*ClusterList) DeepCopyInto

func (in *ClusterList) DeepCopyInto(out *ClusterList)

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

func (*ClusterList) DeepCopyObject

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

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

type ClusterPhase

type ClusterPhase string

ClusterPhase Valkey Cluster status

const (
	ClusterPhaseReady ClusterPhase = "Ready"
	// ClusterStatusKO ClusterPhase KO
	ClusterPhaseFailed ClusterPhase = "Failed"
	// clusterStatusPaused cluster status paused
	ClusterPhasePaused ClusterPhase = "Paused"
	// ClusterStatusCreating ClusterPhase Creating
	ClusterPhaseCreating ClusterPhase = "Creating"
	// ClusterStatusRollingUpdate ClusterPhase RollingUpdate
	ClusterPhaseRollingUpdate ClusterPhase = "RollingUpdate"
	// ClusterStatusRebalancing ClusterPhase rebalancing
	ClusterPhaseRebalancing ClusterPhase = "Rebalancing"
)

type ClusterReplicas

type ClusterReplicas struct {
	// Shards is the number of cluster shards
	// +kubebuilder:validation:Minimum=3
	// +kubebuilder:validation:Maximum=128
	// +kubebuilder:validation:Required
	// +kubebuilder:default=3
	Shards int32 `json:"shards"`

	// ShardsConfig is the configuration of each shard
	// +kubebuilder:validation:MinItems=3
	// +optional
	ShardsConfig []*ShardConfig `json:"shardsConfig,omitempty"`

	// ReplicasOfShard is the number of replicas for each master node
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=5
	ReplicasOfShard int32 `json:"replicasOfShard"`
}

ClusterReplicas

func (*ClusterReplicas) DeepCopy

func (in *ClusterReplicas) DeepCopy() *ClusterReplicas

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

func (*ClusterReplicas) DeepCopyInto

func (in *ClusterReplicas) DeepCopyInto(out *ClusterReplicas)

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

type ClusterServiceStatus

type ClusterServiceStatus string

ClusterServiceStatus

const (
	ClusterInService    ClusterServiceStatus = "InService"
	ClusterOutOfService ClusterServiceStatus = "OutOfService"
)

type ClusterShards

type ClusterShards struct {
	// ID match the shard-id in cluster shard
	Id string `json:"id,omitempty"`
	// Index the shard index
	Index int32 `json:"index"`
	// Slots records the slots status of this shard
	Slots []*ClusterShardsSlotStatus `json:"slots"`
}

ClusterShards

func (*ClusterShards) DeepCopy

func (in *ClusterShards) DeepCopy() *ClusterShards

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

func (*ClusterShards) DeepCopyInto

func (in *ClusterShards) DeepCopyInto(out *ClusterShards)

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

type ClusterShardsSlotStatus

type ClusterShardsSlotStatus struct {
	// Slots slots this shard holds or will holds
	Slots string `json:"slots,omitempty"`
	// Status the status of this status
	Status string `json:"status,omitempty"`
	// ShardIndex indicates the slots importing from or migrate to
	ShardIndex *int32 `json:"shardId"`
}

ClusterShardsSlotStatus

func (*ClusterShardsSlotStatus) DeepCopy

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

func (*ClusterShardsSlotStatus) DeepCopyInto

func (in *ClusterShardsSlotStatus) DeepCopyInto(out *ClusterShardsSlotStatus)

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

type ClusterSpec

type ClusterSpec struct {
	// Image valkey image
	Image string `json:"image,omitempty"`
	// ImagePullPolicy is the image pull policy
	ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"`
	// ImagePullSecrets
	ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`

	// Replicas is the number of cluster replicas
	Replicas ClusterReplicas `json:"replicas"`

	// CustomConfigs is the custom configuration
	//
	// Most of the settings is key-value format.
	CustomConfigs map[string]string `json:"customConfigs,omitempty"`

	// Resources
	Resources corev1.ResourceRequirements `json:"resources,omitempty"`

	// Access defines the access for valkey
	Access core.InstanceAccess `json:"access,omitempty"`
	// Storage
	Storage *core.Storage `json:"storage,omitempty"`

	// Exporter
	Exporter *core.Exporter `json:"exporter,omitempty"`

	// PodAnnotations
	PodAnnotations map[string]string `json:"annotations,omitempty"`
	// AffinityPolicy
	// +kubebuilder:validation:Enum=SoftAntiAffinity;AntiAffinityInShard;AntiAffinity;CustomAffinity
	AffinityPolicy *core.AffinityPolicy `json:"affinityPolicy,omitempty"`
	// Affinity
	CustomAffinity *corev1.Affinity `json:"CustomAffinity,omitempty"`
	// NodeSelector
	NodeSelector map[string]string `json:"nodeSelector,omitempty"`
	// Tolerations
	Tolerations []corev1.Toleration `json:"tolerations,omitempty"`
	// SecurityContext
	SecurityContext *corev1.PodSecurityContext `json:"securityContext,omitempty"`

	// Modules defines the module settings for Valkey
	Modules []core.ValkeyModule `json:"modules,omitempty"`
}

ClusterSpec defines the desired state of Cluster

func (*ClusterSpec) DeepCopy

func (in *ClusterSpec) DeepCopy() *ClusterSpec

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

func (*ClusterSpec) DeepCopyInto

func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec)

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

type ClusterStatus

type ClusterStatus struct {
	// Status the status of the cluster
	Phase ClusterPhase `json:"phase"`
	// Message the message of the status
	Message string `json:"message,omitempty"`
	// Nodes the cluster nodes
	Nodes []core.ValkeyNode `json:"nodes,omitempty"`
	// ServiceStatus the cluster service status
	ServiceStatus ClusterServiceStatus `json:"clusterStatus,omitempty"`
	// Shards the cluster shards
	Shards []*ClusterShards `json:"shards,omitempty"`
}

ClusterStatus defines the observed state of Cluster

func (*ClusterStatus) DeepCopy

func (in *ClusterStatus) DeepCopy() *ClusterStatus

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

func (*ClusterStatus) DeepCopyInto

func (in *ClusterStatus) DeepCopyInto(out *ClusterStatus)

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

type Failover

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

	Spec   FailoverSpec   `json:"spec,omitempty"`
	Status FailoverStatus `json:"status,omitempty"`
}

Failover is the Schema for the failovers API

func (*Failover) DeepCopy

func (in *Failover) DeepCopy() *Failover

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

func (*Failover) DeepCopyInto

func (in *Failover) DeepCopyInto(out *Failover)

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

func (*Failover) DeepCopyObject

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

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

type FailoverList

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

FailoverList contains a list of Failover

func (*FailoverList) DeepCopy

func (in *FailoverList) DeepCopy() *FailoverList

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

func (*FailoverList) DeepCopyInto

func (in *FailoverList) DeepCopyInto(out *FailoverList)

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

func (*FailoverList) DeepCopyObject

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

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

type FailoverPhase

type FailoverPhase string
const (
	FailoverPhaseReady    FailoverPhase = "Ready"
	FailoverPhaseFailed   FailoverPhase = "Failed"
	FailoverPhasePaused   FailoverPhase = "Paused"
	FailoverPhaseCreating FailoverPhase = "Creating"
)

type FailoverPolicy

type FailoverPolicy string
const (
	SentinelFailoverPolicy FailoverPolicy = "sentinel"
	ManualFailoverPolicy   FailoverPolicy = "manual"
)

type FailoverSpec

type FailoverSpec struct {
	Image            string                        `json:"image,omitempty"`
	ImagePullPolicy  corev1.PullPolicy             `json:"imagePullPolicy,omitempty"`
	ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`

	Replicas  int32                       `json:"replicas,omitempty"`
	Resources corev1.ResourceRequirements `json:"resources,omitempty"`
	// CustomConfig custom valkey configuration
	CustomConfigs map[string]string `json:"customConfigs,omitempty"`
	// Storage
	Storage *core.Storage `json:"storage,omitempty"`

	// Exporter
	Exporter *core.Exporter `json:"exporter,omitempty"`
	// Access
	Access core.InstanceAccess `json:"access,omitempty"`

	PodAnnotations  map[string]string          `json:"podAnnotations,omitempty"`
	Affinity        *corev1.Affinity           `json:"affinity,omitempty"`
	Tolerations     []corev1.Toleration        `json:"tolerations,omitempty"`
	NodeSelector    map[string]string          `json:"nodeSelector,omitempty"`
	SecurityContext *corev1.PodSecurityContext `json:"securityContext,omitempty"`

	// Sentinel
	Sentinel *SentinelSettings `json:"sentinel,omitempty"`

	// Modules defines the module settings for Valkey
	Modules []core.ValkeyModule `json:"modules,omitempty"`
}

FailoverSpec defines the desired state of Failover

func (*FailoverSpec) DeepCopy

func (in *FailoverSpec) DeepCopy() *FailoverSpec

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

func (*FailoverSpec) DeepCopyInto

func (in *FailoverSpec) DeepCopyInto(out *FailoverSpec)

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

type FailoverStatus

type FailoverStatus struct {
	// Phase
	Phase FailoverPhase `json:"phase,omitempty"`
	// Message the status message
	Message string `json:"message,omitempty"`
	// Nodes the valkey cluster nodes
	Nodes []core.ValkeyNode `json:"nodes,omitempty"`
	// TLSSecret the tls secret
	TLSSecret string `json:"tlsSecret,omitempty"`
	// Monitor the monitor status
	Monitor MonitorStatus `json:"monitor,omitempty"`
}

FailoverStatus defines the observed state of Failover

func (*FailoverStatus) DeepCopy

func (in *FailoverStatus) DeepCopy() *FailoverStatus

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

func (*FailoverStatus) DeepCopyInto

func (in *FailoverStatus) DeepCopyInto(out *FailoverStatus)

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

type MonitorStatus

type MonitorStatus struct {
	// Policy the failover policy
	Policy FailoverPolicy `json:"policy,omitempty"`
	// Name monitor name
	Name string `json:"name,omitempty"`
	// Username sentinel username
	Username string `json:"username,omitempty"`
	// PasswordSecret
	PasswordSecret string `json:"passwordSecret,omitempty"`
	// OldPasswordSecret
	OldPasswordSecret string `json:"oldPasswordSecret,omitempty"`
	// TLSSecret the tls secret
	TLSSecret string `json:"tlsSecret,omitempty"`
	// Nodes the sentinel monitor nodes
	Nodes []SentinelMonitorNode `json:"nodes,omitempty"`
}

func (*MonitorStatus) DeepCopy

func (in *MonitorStatus) DeepCopy() *MonitorStatus

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

func (*MonitorStatus) DeepCopyInto

func (in *MonitorStatus) DeepCopyInto(out *MonitorStatus)

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

type Sentinel

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

	Spec   SentinelSpec   `json:"spec,omitempty"`
	Status SentinelStatus `json:"status,omitempty"`
}

Sentinel is the Schema for the sentinels API

func (*Sentinel) DeepCopy

func (in *Sentinel) DeepCopy() *Sentinel

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

func (*Sentinel) DeepCopyInto

func (in *Sentinel) DeepCopyInto(out *Sentinel)

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

func (*Sentinel) DeepCopyObject

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

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

type SentinelInstanceAccess

type SentinelInstanceAccess struct {
	core.InstanceAccess `json:",inline"`

	// DefaultPasswordSecret referered to the secret which defined the password for default user
	// The referered secret must have `password` key whose value matching regex: ^[a-zA-Z0-9_!@#$%^&*()-_=+?]{8,128}$
	// +optional
	DefaultPasswordSecret string `json:"defaultPasswordSecret,omitempty"`

	// ExternalTLSSecret the external TLS secret to use, if not provided, the operator will issue one
	ExternalTLSSecret string `json:"externalTLSSecret,omitempty"`
}

SentinelInstanceAccess

func (*SentinelInstanceAccess) DeepCopy

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

func (*SentinelInstanceAccess) DeepCopyInto

func (in *SentinelInstanceAccess) DeepCopyInto(out *SentinelInstanceAccess)

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

type SentinelList

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

SentinelList contains a list of Sentinel

func (*SentinelList) DeepCopy

func (in *SentinelList) DeepCopy() *SentinelList

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

func (*SentinelList) DeepCopyInto

func (in *SentinelList) DeepCopyInto(out *SentinelList)

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

func (*SentinelList) DeepCopyObject

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

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

type SentinelMonitorNode

type SentinelMonitorNode struct {
	// IP the sentinel node ip
	IP string `json:"ip,omitempty"`
	// Port the sentinel node port
	Port int32 `json:"port,omitempty"`
	// Flags
	Flags string `json:"flags,omitempty"`
}

func (*SentinelMonitorNode) DeepCopy

func (in *SentinelMonitorNode) DeepCopy() *SentinelMonitorNode

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

func (*SentinelMonitorNode) DeepCopyInto

func (in *SentinelMonitorNode) DeepCopyInto(out *SentinelMonitorNode)

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

type SentinelPhase

type SentinelPhase string

SentinelPhase

const (
	// SentinelCreating the sentinel creating phase
	SentinelCreating SentinelPhase = "Creating"
	// SentinelPaused the sentinel paused phase
	SentinelPaused SentinelPhase = "Paused"
	// SentinelReady the sentinel ready phase
	SentinelReady SentinelPhase = "Ready"
	// SentinelFail the sentinel fail phase
	SentinelFailed SentinelPhase = "Failed"
)

type SentinelReference

type SentinelReference struct {
	// Addresses the sentinel addresses
	// +kubebuilder:validation:MinItems=3
	Nodes []SentinelMonitorNode `json:"nodes,omitempty"`
	// Auth the sentinel auth
	Auth Authorization `json:"auth,omitempty"`
}

SentinelReference defines the sentinel reference

func (*SentinelReference) DeepCopy

func (in *SentinelReference) DeepCopy() *SentinelReference

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

func (*SentinelReference) DeepCopyInto

func (in *SentinelReference) DeepCopyInto(out *SentinelReference)

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

type SentinelSettings

type SentinelSettings struct {
	SentinelSpec `json:",inline"`

	// SentinelReference the sentinel reference
	SentinelReference *SentinelReference `json:"sentinelReference,omitempty"`

	// MonitorConfig configs for sentinel to monitor this replication, including:
	// - down-after-milliseconds
	// - failover-timeout
	// - parallel-syncs
	MonitorConfig map[string]string `json:"monitorConfig,omitempty"`

	// Quorum the number of Sentinels that need to agree about the fact the master is not reachable,
	// in order to really mark the master as failing, and eventually start a failover procedure if possible.
	// If not specified, the default value is the majority of the Sentinels.
	Quorum *int32 `json:"quorum,omitempty"`
}

SentinelSettings defines the specification of the sentinel cluster

func (*SentinelSettings) DeepCopy

func (in *SentinelSettings) DeepCopy() *SentinelSettings

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

func (*SentinelSettings) DeepCopyInto

func (in *SentinelSettings) DeepCopyInto(out *SentinelSettings)

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

type SentinelSpec

type SentinelSpec struct {
	// Image the valkey sentinel image
	Image string `json:"image,omitempty"`

	// ImagePullPolicy the image pull policy
	ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"`

	// ImagePullSecrets the image pull secrets
	ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`

	// Replicas the number of sentinel replicas
	//
	// +kubebuilder:validation:Minimum=3
	Replicas int32 `json:"replicas,omitempty"`

	// Resources the resources for sentinel
	Resources corev1.ResourceRequirements `json:"resources,omitempty"`

	// CustomConfigs the config for sentinel
	CustomConfigs map[string]string `json:"customConfigs,omitempty"`

	// Exporter defines the specification for the sentinel exporter
	Exporter *core.Exporter `json:"exporter,omitempty"`

	// Access the access for sentinel
	Access SentinelInstanceAccess `json:"access,omitempty"`

	// Affinity
	Affinity *corev1.Affinity `json:"affinity,omitempty"`
	// SecurityContext
	SecurityContext *corev1.PodSecurityContext `json:"securityContext,omitempty"`
	// Tolerations
	Tolerations []corev1.Toleration `json:"tolerations,omitempty"`
	// NodeSelector
	NodeSelector map[string]string `json:"nodeSelector,omitempty"`
	// PodAnnotations
	PodAnnotations map[string]string `json:"podAnnotations,omitempty"`
}

SentinelSpec defines the desired state of Sentinel

func (*SentinelSpec) DeepCopy

func (in *SentinelSpec) DeepCopy() *SentinelSpec

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

func (*SentinelSpec) DeepCopyInto

func (in *SentinelSpec) DeepCopyInto(out *SentinelSpec)

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

type SentinelStatus

type SentinelStatus struct {
	// Phase the status phase
	Phase SentinelPhase `json:"phase,omitempty"`
	// Message the status message
	Message string `json:"message,omitempty"`
	// Nodes the valkey node details
	Nodes []core.ValkeyNode `json:"nodes,omitempty"`
	// TLSSecret the tls secret
	TLSSecret string `json:"tlsSecret,omitempty"`
}

SentinelStatus defines the observed state of Sentinel

func (*SentinelStatus) DeepCopy

func (in *SentinelStatus) DeepCopy() *SentinelStatus

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

func (*SentinelStatus) DeepCopyInto

func (in *SentinelStatus) DeepCopyInto(out *SentinelStatus)

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

type ShardConfig

type ShardConfig struct {
	// Slots is the slot range for the shard, eg: 0-1000,1002,1005-1100
	//+kubebuilder:validation:Pattern:=`^(\d{1,5}|(\d{1,5}-\d{1,5}))(,(\d{1,5}|(\d{1,5}-\d{1,5})))*$`
	Slots string `json:"slots,omitempty"`
}

func (*ShardConfig) DeepCopy

func (in *ShardConfig) DeepCopy() *ShardConfig

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

func (*ShardConfig) DeepCopyInto

func (in *ShardConfig) DeepCopyInto(out *ShardConfig)

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

type User

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

	Spec   UserSpec   `json:"spec,omitempty"`
	Status UserStatus `json:"status,omitempty"`
}

User is the Schema for the users API

func (*User) DeepCopy

func (in *User) DeepCopy() *User

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

func (*User) DeepCopyInto

func (in *User) DeepCopyInto(out *User)

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

func (*User) DeepCopyObject

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

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

type UserList

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

UserList contains a list of User

func (*UserList) DeepCopy

func (in *UserList) DeepCopy() *UserList

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

func (*UserList) DeepCopyInto

func (in *UserList) DeepCopyInto(out *UserList)

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

func (*UserList) DeepCopyObject

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

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

type UserPhase

type UserPhase string
const (
	UserFail    UserPhase = "Fail"
	UserReady   UserPhase = "Ready"
	UserPending UserPhase = "Pending"
)

type UserSpec

type UserSpec struct {
	// user account type
	// +kubebuilder:validation:Enum=system;custom
	AccountType AccountType `json:"accountType,omitempty"`
	// user account type
	// +kubebuilder:validation:Enum=failover;cluster;replica
	Arch core.Arch `json:"arch,omitempty"`
	// Username (required)
	Username string `json:"username"`
	// PasswordSecrets Password secret name, key is password
	PasswordSecrets []string `json:"passwordSecrets,omitempty"`
	// AclRules acl rules  string
	AclRules string `json:"aclRules,omitempty"`
	// InstanceName instance  Name (required)
	// +kubebuilder:validation:MaxLength=63
	// +kubebuilder:validation:MinLength=1
	InstanceName string `json:"instanceName"`
}

UserSpec defines the desired state of User

func (*UserSpec) DeepCopy

func (in *UserSpec) DeepCopy() *UserSpec

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

func (*UserSpec) DeepCopyInto

func (in *UserSpec) DeepCopyInto(out *UserSpec)

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

type UserStatus

type UserStatus struct {
	// Phase
	Phase UserPhase `json:"Phase,omitempty"`

	// Message
	Message string `json:"message,omitempty"`

	// AclRules acl rules of valkey
	AclRules string `json:"aclRules,omitempty"`
}

UserStatus defines the observed state of User

func (*UserStatus) DeepCopy

func (in *UserStatus) DeepCopy() *UserStatus

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

func (*UserStatus) DeepCopyInto

func (in *UserStatus) DeepCopyInto(out *UserStatus)

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