v1

package
v0.0.0-...-cb4c79d Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2019 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

+k8s:deepcopy-gen=package,register +groupName=redis.operator.joelws.com

Index

Constants

View Source
const (
	CRDResourceKind = "Redis"
	RedisGroupName  = "operator.joelws.com"
)

Variables

View Source
var (
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)
View Source
var SchemeGroupVersion = schema.GroupVersion{Group: RedisGroupName, Version: "v1"}

Functions

func RegisterDeepCopies deprecated

func RegisterDeepCopies(scheme *runtime.Scheme) error

RegisterDeepCopies adds deep-copy functions to the given scheme. Public to allow building arbitrary schemes.

Deprecated: deepcopy registration will go away when static deepcopy is fully implemented.

func Resource

func Resource(resource string) schema.GroupResource

Types

type ConfigMap

type ConfigMap string

type PodPolicy

type PodPolicy struct {
	Resources v1.ResourceRequirements `json:"resources,omitempty"`
}

func (*PodPolicy) DeepCopy

func (in *PodPolicy) DeepCopy() *PodPolicy

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

func (*PodPolicy) DeepCopyInto

func (in *PodPolicy) DeepCopyInto(out *PodPolicy)

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

type Redis

type Redis struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              ServerSpec   `json:"spec"`
	Status            ServerStatus `json:"status"`
}

func (*Redis) AsOwner

func (c *Redis) AsOwner() metav1.OwnerReference

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.

type RedisList

type RedisList struct {
	metav1.TypeMeta `json:",inline"`
	// Standard list metadata
	// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Redis `json:"items"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

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 SentinelSpec

type SentinelSpec struct {
	Replicas  int32     `json:"replicas"`
	Quorum    int32     `json:"quorum"`
	ConfigMap ConfigMap `json:"configMap"`
}

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 {
	Ready   []string `json:"ready,omitempty"`
	Unready []string `json:"unready,omitempty"`
}

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 ServerCondition

type ServerCondition struct {
	Type   ServerConditionType `json:"type"`
	Reason string              `json:"reason,omitempty"`
}

func (*ServerCondition) DeepCopy

func (in *ServerCondition) DeepCopy() *ServerCondition

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

func (*ServerCondition) DeepCopyInto

func (in *ServerCondition) DeepCopyInto(out *ServerCondition)

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

type ServerConditionType

type ServerConditionType string
const (
	ServerConditionAddSeedMaster    ServerConditionType = "AddingSeedMaster"
	ServerConditionRemoveSeedMaster ServerConditionType = "removingSeedMaster"
	ServerConditionAddSentinel      ServerConditionType = "AddingSentinel"
	ServerConditionRemoveSentinel   ServerConditionType = "removingSentinel"
	ServerConditionAddSlave         ServerConditionType = "AddingSlave"
	ServerConditionRemoveSlave      ServerConditionType = "removingSlave"
	ServerConditionReady            ServerConditionType = "Ready"
)

type ServerPhase

type ServerPhase string
const (
	ServerCreatingPhase ServerPhase = "Creating"
	ServerStoppingPhase ServerPhase = "Stopping"
	ServerRunningPhase  ServerPhase = "Running"
	ServerFailedPhase   ServerPhase = "Failed"
)

type ServerSpec

type ServerSpec struct {
	Sentinels SentinelSpec `json:"sentinels"`

	Slaves SlaveSpec `json:"slaves"`

	BaseImage string `json:"baseImage,omitempty"`

	Version string `json:"version,omitempty"`

	Paused bool `json:"paused,omitempty"`

	Pod *PodPolicy `json:"pod,omitempty"`
}

func (*ServerSpec) ApplyDefaults

func (s *ServerSpec) ApplyDefaults(name string)

func (*ServerSpec) DeepCopy

func (in *ServerSpec) DeepCopy() *ServerSpec

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

func (*ServerSpec) DeepCopyInto

func (in *ServerSpec) DeepCopyInto(out *ServerSpec)

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

func (*ServerSpec) GetRedisRunAsUser

func (s *ServerSpec) GetRedisRunAsUser() (runAsPointer *int64)

Adding runAsUser: 100 to ContainerSpec as it failed to chown (related to underlaying storage config)

type ServerStatus

type ServerStatus struct {
	Phase          ServerPhase       `json:"phase"`
	Conditions     []ServerCondition `json:"conditions"`
	SlaveStatus    SlaveStatus       `json:"slaves"`
	SentinelStatus SentinelStatus    `json:"sentinels"`
}

func (*ServerStatus) DeepCopy

func (in *ServerStatus) DeepCopy() *ServerStatus

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

func (*ServerStatus) DeepCopyInto

func (in *ServerStatus) DeepCopyInto(out *ServerStatus)

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

func (*ServerStatus) MarkAddSeedMasterCondition

func (ss *ServerStatus) MarkAddSeedMasterCondition()

func (*ServerStatus) MarkAddSentinelCondition

func (ss *ServerStatus) MarkAddSentinelCondition()

func (*ServerStatus) MarkAddSlaveCondition

func (ss *ServerStatus) MarkAddSlaveCondition()

func (*ServerStatus) MarkReadyCondition

func (ss *ServerStatus) MarkReadyCondition()

func (*ServerStatus) MarkRemoveSeedMasterCondition

func (ss *ServerStatus) MarkRemoveSeedMasterCondition()

func (*ServerStatus) MarkRemoveSentinelCondition

func (ss *ServerStatus) MarkRemoveSentinelCondition()

func (*ServerStatus) MarkRemoveSlaveCondition

func (ss *ServerStatus) MarkRemoveSlaveCondition()

func (*ServerStatus) SetPhase

func (ss *ServerStatus) SetPhase(phase ServerPhase)

type SlaveSpec

type SlaveSpec struct {
	Replicas  int32     `json:"replicas"`
	ConfigMap ConfigMap `json:"configMap"`
}

func (*SlaveSpec) DeepCopy

func (in *SlaveSpec) DeepCopy() *SlaveSpec

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

func (*SlaveSpec) DeepCopyInto

func (in *SlaveSpec) DeepCopyInto(out *SlaveSpec)

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

type SlaveStatus

type SlaveStatus struct {
	Ready   []string `json:"ready,omitempty"`
	Unready []string `json:"unready,omitempty"`
}

func (*SlaveStatus) DeepCopy

func (in *SlaveStatus) DeepCopy() *SlaveStatus

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

func (*SlaveStatus) DeepCopyInto

func (in *SlaveStatus) DeepCopyInto(out *SlaveStatus)

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