Documentation
¶
Overview ¶
Package v1 contains API Schema definitions for the openldap v1 API group +kubebuilder:object:generate=true +groupName=openldap.kwonjin.click
Index ¶
- Constants
- Variables
- type ClusterPodTemplate
- type MonitorConfig
- type OpenldapCluster
- func (r *OpenldapCluster) AdminDn() string
- func (r *OpenldapCluster) ConfigMapName() string
- func (in *OpenldapCluster) DeepCopy() *OpenldapCluster
- func (in *OpenldapCluster) DeepCopyInto(out *OpenldapCluster)
- func (in *OpenldapCluster) DeepCopyObject() runtime.Object
- func (r *OpenldapCluster) Default()
- func (r *OpenldapCluster) DefaultLabels() map[string]string
- func (r *OpenldapCluster) DeleteCurrentMaster()
- func (r *OpenldapCluster) DeleteInitializedCondition()
- func (r *OpenldapCluster) ExporterImage() string
- func (r *OpenldapCluster) ExporterName() string
- func (r *OpenldapCluster) GetAnnotations() map[string]string
- func (r *OpenldapCluster) GetCondition() metav1.Condition
- func (r *OpenldapCluster) GetCurrentMaster() string
- func (r *OpenldapCluster) GetDesiredMaster() string
- func (r *OpenldapCluster) GetMasterLabels() map[string]string
- func (r *OpenldapCluster) GetReplicas() int
- func (r *OpenldapCluster) GetSlaveLabels() map[string]string
- func (r *OpenldapCluster) GetTemplate() ClusterPodTemplate
- func (r *OpenldapCluster) GetTemplateLabels() map[string]string
- func (r *OpenldapCluster) InitContainerName() string
- func (r *OpenldapCluster) IsConditionsEmpty() bool
- func (r *OpenldapCluster) IsElected() bool
- func (r *OpenldapCluster) IsInitialized() bool
- func (r *OpenldapCluster) IsMasterSame() bool
- func (r *OpenldapCluster) IsReady() bool
- func (r *OpenldapCluster) JobLabels() map[string]string
- func (r *OpenldapCluster) JobName() string
- func (r *OpenldapCluster) LdapPort() int32
- func (r *OpenldapCluster) LdapsPort() int32
- func (r *OpenldapCluster) MasterSelectorLabels() map[string]string
- func (r *OpenldapCluster) MetricsPath() string
- func (r *OpenldapCluster) MetricsPort() int32
- func (r *OpenldapCluster) MetricsPortName() string
- func (r *OpenldapCluster) MetricsServiceName() string
- func (r *OpenldapCluster) MonitorEnabled() bool
- func (r *OpenldapCluster) PodName(index int) string
- func (r *OpenldapCluster) ReadServiceName() string
- func (r *OpenldapCluster) SeedDataPath() string
- func (r *OpenldapCluster) SelectorLabels() map[string]string
- func (r *OpenldapCluster) SetConditionElected(condition bool)
- func (r *OpenldapCluster) SetConditionReady(condition bool)
- func (r *OpenldapCluster) SetDefault()
- func (r *OpenldapCluster) SetInitCondition()
- func (r *OpenldapCluster) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (r *OpenldapCluster) SlaveSelectorLabels() map[string]string
- func (r *OpenldapCluster) TlsEnabled() bool
- func (r *OpenldapCluster) TlsMountPath() string
- func (r *OpenldapCluster) UpdateCurrentMaster()
- func (r *OpenldapCluster) UpdateDesiredMaster(index int)
- func (r *OpenldapCluster) ValidateCreate() error
- func (r *OpenldapCluster) ValidateDelete() error
- func (r *OpenldapCluster) ValidateUpdate(old runtime.Object) error
- func (r *OpenldapCluster) WriteServiceName() string
- type OpenldapClusterList
- type OpenldapClusterSpec
- type OpenldapClusterStatus
- type OpenldapConfig
- type PortConfig
- type SecretOrConfigMapVolumeSource
- type StorageConfig
- type TlsConfig
Constants ¶
const ( ConditionInitialized = "Initialized" ConditionReady = "Ready" ConditionElected = "Elected" )
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "openldap.kwonjin.click", Version: "v1"} // 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 ClusterPodTemplate ¶
type ClusterPodTemplate struct {
// Openldap image based on qwp1216/openldap
//+kubebuilder:default:="qwp1216/openldap:2.6.4"
Image string `json:"image,omitempty"`
//+optional
ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"`
//+optional
Labels map[string]string `json:"labels,omitempty"`
//+optional
Annotations map[string]string `json:"annotations,omitempty"`
//+optional
Resources corev1.ResourceRequirements `json:"resources,omitempty"`
//+optional
Env []corev1.EnvVar `json:"env,omitempty"`
//+optional
Affinity *corev1.Affinity `json:"affinity,omitempty"`
//+optional
NodeSelector map[string]string `json:"nodeSelector,omitempty"`
//+optional
Tolerations []corev1.Toleration `json:"tolerations,omitempty"`
//+optional
PriorityClassName string `json:"priorityClassName,omitempty"`
//+optional
Ports *PortConfig `json:"ports,omitempty"`
}
func (*ClusterPodTemplate) DeepCopy ¶
func (in *ClusterPodTemplate) DeepCopy() *ClusterPodTemplate
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPodTemplate.
func (*ClusterPodTemplate) DeepCopyInto ¶
func (in *ClusterPodTemplate) DeepCopyInto(out *ClusterPodTemplate)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type MonitorConfig ¶
type MonitorConfig struct {
//+kubebuilder:default:=false
Enabled bool `json:"enabled,omitempty"`
//+optional
Labels map[string]string `json:"labels,omitempty"`
//+kubebuilder:default:="30s"
Interval string `json:"interval,omitempty"`
//+kubebuilder:default:="10s"
ScrapeTimeout string `json:"scrapeTimeout,omitempty"`
}
func (*MonitorConfig) DeepCopy ¶
func (in *MonitorConfig) DeepCopy() *MonitorConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MonitorConfig.
func (*MonitorConfig) DeepCopyInto ¶
func (in *MonitorConfig) DeepCopyInto(out *MonitorConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type OpenldapCluster ¶
type OpenldapCluster struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec OpenldapClusterSpec `json:"spec,omitempty"`
Status OpenldapClusterStatus `json:"status,omitempty"`
}
OpenldapCluster is the Schema for the openldapclusters API
func (*OpenldapCluster) AdminDn ¶
func (r *OpenldapCluster) AdminDn() string
func (*OpenldapCluster) ConfigMapName ¶
func (r *OpenldapCluster) ConfigMapName() string
func (*OpenldapCluster) DeepCopy ¶
func (in *OpenldapCluster) DeepCopy() *OpenldapCluster
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OpenldapCluster.
func (*OpenldapCluster) DeepCopyInto ¶
func (in *OpenldapCluster) DeepCopyInto(out *OpenldapCluster)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*OpenldapCluster) DeepCopyObject ¶
func (in *OpenldapCluster) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*OpenldapCluster) Default ¶
func (r *OpenldapCluster) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (*OpenldapCluster) DefaultLabels ¶
func (r *OpenldapCluster) DefaultLabels() map[string]string
func (*OpenldapCluster) DeleteCurrentMaster ¶
func (r *OpenldapCluster) DeleteCurrentMaster()
func (*OpenldapCluster) DeleteInitializedCondition ¶
func (r *OpenldapCluster) DeleteInitializedCondition()
func (*OpenldapCluster) ExporterImage ¶
func (r *OpenldapCluster) ExporterImage() string
func (*OpenldapCluster) ExporterName ¶
func (r *OpenldapCluster) ExporterName() string
func (*OpenldapCluster) GetAnnotations ¶
func (r *OpenldapCluster) GetAnnotations() map[string]string
func (*OpenldapCluster) GetCondition ¶
func (r *OpenldapCluster) GetCondition() metav1.Condition
func (*OpenldapCluster) GetCurrentMaster ¶
func (r *OpenldapCluster) GetCurrentMaster() string
func (*OpenldapCluster) GetDesiredMaster ¶
func (r *OpenldapCluster) GetDesiredMaster() string
func (*OpenldapCluster) GetMasterLabels ¶
func (r *OpenldapCluster) GetMasterLabels() map[string]string
func (*OpenldapCluster) GetReplicas ¶
func (r *OpenldapCluster) GetReplicas() int
func (*OpenldapCluster) GetSlaveLabels ¶
func (r *OpenldapCluster) GetSlaveLabels() map[string]string
func (*OpenldapCluster) GetTemplate ¶
func (r *OpenldapCluster) GetTemplate() ClusterPodTemplate
func (*OpenldapCluster) GetTemplateLabels ¶
func (r *OpenldapCluster) GetTemplateLabels() map[string]string
func (*OpenldapCluster) InitContainerName ¶
func (r *OpenldapCluster) InitContainerName() string
func (*OpenldapCluster) IsConditionsEmpty ¶
func (r *OpenldapCluster) IsConditionsEmpty() bool
func (*OpenldapCluster) IsElected ¶
func (r *OpenldapCluster) IsElected() bool
func (*OpenldapCluster) IsInitialized ¶
func (r *OpenldapCluster) IsInitialized() bool
func (*OpenldapCluster) IsMasterSame ¶
func (r *OpenldapCluster) IsMasterSame() bool
func (*OpenldapCluster) IsReady ¶
func (r *OpenldapCluster) IsReady() bool
func (*OpenldapCluster) JobLabels ¶
func (r *OpenldapCluster) JobLabels() map[string]string
func (*OpenldapCluster) JobName ¶
func (r *OpenldapCluster) JobName() string
func (*OpenldapCluster) LdapPort ¶
func (r *OpenldapCluster) LdapPort() int32
func (*OpenldapCluster) LdapsPort ¶
func (r *OpenldapCluster) LdapsPort() int32
func (*OpenldapCluster) MasterSelectorLabels ¶
func (r *OpenldapCluster) MasterSelectorLabels() map[string]string
func (*OpenldapCluster) MetricsPath ¶
func (r *OpenldapCluster) MetricsPath() string
func (*OpenldapCluster) MetricsPort ¶
func (r *OpenldapCluster) MetricsPort() int32
func (*OpenldapCluster) MetricsPortName ¶
func (r *OpenldapCluster) MetricsPortName() string
func (*OpenldapCluster) MetricsServiceName ¶
func (r *OpenldapCluster) MetricsServiceName() string
func (*OpenldapCluster) MonitorEnabled ¶
func (r *OpenldapCluster) MonitorEnabled() bool
func (*OpenldapCluster) PodName ¶
func (r *OpenldapCluster) PodName(index int) string
func (*OpenldapCluster) ReadServiceName ¶
func (r *OpenldapCluster) ReadServiceName() string
func (*OpenldapCluster) SeedDataPath ¶
func (r *OpenldapCluster) SeedDataPath() string
func (*OpenldapCluster) SelectorLabels ¶
func (r *OpenldapCluster) SelectorLabels() map[string]string
func (*OpenldapCluster) SetConditionElected ¶
func (r *OpenldapCluster) SetConditionElected(condition bool)
func (*OpenldapCluster) SetConditionReady ¶
func (r *OpenldapCluster) SetConditionReady(condition bool)
func (*OpenldapCluster) SetDefault ¶
func (r *OpenldapCluster) SetDefault()
func (*OpenldapCluster) SetInitCondition ¶
func (r *OpenldapCluster) SetInitCondition()
func (*OpenldapCluster) SetupWebhookWithManager ¶
func (r *OpenldapCluster) SetupWebhookWithManager(mgr ctrl.Manager) error
func (*OpenldapCluster) SlaveSelectorLabels ¶
func (r *OpenldapCluster) SlaveSelectorLabels() map[string]string
func (*OpenldapCluster) TlsEnabled ¶
func (r *OpenldapCluster) TlsEnabled() bool
func (*OpenldapCluster) TlsMountPath ¶
func (r *OpenldapCluster) TlsMountPath() string
func (*OpenldapCluster) UpdateCurrentMaster ¶
func (r *OpenldapCluster) UpdateCurrentMaster()
func (*OpenldapCluster) UpdateDesiredMaster ¶
func (r *OpenldapCluster) UpdateDesiredMaster(index int)
func (*OpenldapCluster) ValidateCreate ¶
func (r *OpenldapCluster) ValidateCreate() error
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*OpenldapCluster) ValidateDelete ¶
func (r *OpenldapCluster) ValidateDelete() error
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
func (*OpenldapCluster) ValidateUpdate ¶
func (r *OpenldapCluster) ValidateUpdate(old runtime.Object) error
ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (*OpenldapCluster) WriteServiceName ¶
func (r *OpenldapCluster) WriteServiceName() string
type OpenldapClusterList ¶
type OpenldapClusterList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []OpenldapCluster `json:"items"`
}
OpenldapClusterList contains a list of OpenldapCluster
func (*OpenldapClusterList) DeepCopy ¶
func (in *OpenldapClusterList) DeepCopy() *OpenldapClusterList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OpenldapClusterList.
func (*OpenldapClusterList) DeepCopyInto ¶
func (in *OpenldapClusterList) DeepCopyInto(out *OpenldapClusterList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*OpenldapClusterList) DeepCopyObject ¶
func (in *OpenldapClusterList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type OpenldapClusterSpec ¶
type OpenldapClusterSpec struct {
//+kubebuilder:validation:Required
Template ClusterPodTemplate `json:"template,omitempty"`
//+optional
ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`
//+kubebuilder:default:=1
//+kubebuilder:validation:Minimum:=1
Replicas int32 `json:"replicas,omitempty"`
//+kubebuilder:validation:Required
Storage *StorageConfig `json:"storage,omitempty"`
//+optional
OpenldapConfig *OpenldapConfig `json:"openldapConfig,omitempty"`
//+optional
Monitor *MonitorConfig `json:"monitor,omitempty"`
}
OpenldapClusterSpec defines the desired state of OpenldapCluster
func (*OpenldapClusterSpec) DeepCopy ¶
func (in *OpenldapClusterSpec) DeepCopy() *OpenldapClusterSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OpenldapClusterSpec.
func (*OpenldapClusterSpec) DeepCopyInto ¶
func (in *OpenldapClusterSpec) DeepCopyInto(out *OpenldapClusterSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type OpenldapClusterStatus ¶
type OpenldapClusterStatus struct {
Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"`
CurrentMaster string `json:"currentMaster,omitempty"`
DesiredMaster string `json:"desiredMaster,omitempty"`
}
OpenldapClusterStatus defines the observed state of OpenldapCluster
func (*OpenldapClusterStatus) DeepCopy ¶
func (in *OpenldapClusterStatus) DeepCopy() *OpenldapClusterStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OpenldapClusterStatus.
func (*OpenldapClusterStatus) DeepCopyInto ¶
func (in *OpenldapClusterStatus) DeepCopyInto(out *OpenldapClusterStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type OpenldapConfig ¶
type OpenldapConfig struct {
//+optional
Tls *TlsConfig `json:"tls,omitempty"`
//+optional
AdminPassword *corev1.SecretKeySelector `json:"adminPassword,omitempty"`
//+optional
//+kubebuilder:default:=admin
AdminUsername string `json:"adminUsername,omitempty"`
//+optional
ConfigPassword *corev1.SecretKeySelector `json:"configPassword,omitempty"`
//+optional
//+kubebuilder:default:=config
ConfigUsername string `json:"configUsername,omitempty"`
//+kubebuilder:validation:Required
Root string `json:"root,omitempty"`
//+optional
SeedData *SecretOrConfigMapVolumeSource `json:"seedData,omitempty"`
}
func (*OpenldapConfig) DeepCopy ¶
func (in *OpenldapConfig) DeepCopy() *OpenldapConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OpenldapConfig.
func (*OpenldapConfig) DeepCopyInto ¶
func (in *OpenldapConfig) DeepCopyInto(out *OpenldapConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PortConfig ¶
type PortConfig struct {
//+kubebuilder:default:=1389
//+kubebuilder:validation:Minimum:=1
Ldap int32 `json:"ldap,omitempty"`
//+kubebuilder:default:=1636
//+kubebuilder:validation:Minimum:=1
Ldaps int32 `json:"ldaps,omitempty"`
}
func (*PortConfig) DeepCopy ¶
func (in *PortConfig) DeepCopy() *PortConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PortConfig.
func (*PortConfig) DeepCopyInto ¶
func (in *PortConfig) DeepCopyInto(out *PortConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SecretOrConfigMapVolumeSource ¶
type SecretOrConfigMapVolumeSource struct {
//+optional
Secret *corev1.SecretVolumeSource `json:"secret,omitempty" protobuf:"bytes,6,opt,name=secret"`
//+optional
ConfigMap *corev1.ConfigMapVolumeSource `json:"configMap,omitempty" protobuf:"bytes,19,opt,name=configMap"`
}
func (*SecretOrConfigMapVolumeSource) DeepCopy ¶
func (in *SecretOrConfigMapVolumeSource) DeepCopy() *SecretOrConfigMapVolumeSource
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretOrConfigMapVolumeSource.
func (*SecretOrConfigMapVolumeSource) DeepCopyInto ¶
func (in *SecretOrConfigMapVolumeSource) DeepCopyInto(out *SecretOrConfigMapVolumeSource)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StorageConfig ¶
type StorageConfig struct {
//+kubebuilder:validation:Required
VolumeClaimTemplate corev1.PersistentVolumeClaimSpec `json:"volumeClaimTemplate,omitempty"`
}
func (*StorageConfig) DeepCopy ¶
func (in *StorageConfig) DeepCopy() *StorageConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StorageConfig.
func (*StorageConfig) DeepCopyInto ¶
func (in *StorageConfig) DeepCopyInto(out *StorageConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type TlsConfig ¶
type TlsConfig struct {
//+kubebuilder:default:=false
Enabled bool `json:"enabled,omitempty"`
//+optional
SecretName string `json:"secretName,omitempty"`
//+optional
CaFile string `json:"caFile,omitempty"`
//+optional
CertFile string `json:"certFile,omitempty"`
//+optional
KeyFile string `json:"keyFile,omitempty"`
}
func (*TlsConfig) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TlsConfig.
func (*TlsConfig) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.