clickhouse.v1.clickHouseInstallation
"define a set of Kubernetes resources (StatefulSet, PVC, Service, ConfigMap) which describe behavior one or more ClickHouse clusters"
Index
fn new(name)
obj metadata
fn withAnnotations(annotations)
fn withAnnotationsMixin(annotations)
fn withClusterName(clusterName)
fn withCreationTimestamp(creationTimestamp)
fn withDeletionGracePeriodSeconds(deletionGracePeriodSeconds)
fn withDeletionTimestamp(deletionTimestamp)
fn withFinalizers(finalizers)
fn withFinalizersMixin(finalizers)
fn withGenerateName(generateName)
fn withGeneration(generation)
fn withLabels(labels)
fn withLabelsMixin(labels)
fn withName(name)
fn withNamespace(namespace)
fn withOwnerReferences(ownerReferences)
fn withOwnerReferencesMixin(ownerReferences)
fn withResourceVersion(resourceVersion)
fn withSelfLink(selfLink)
fn withUid(uid)
obj spec
fn withNamespaceDomainPattern(namespaceDomainPattern)
fn withRestart(restart)
fn withStop(stop)
fn withTaskID(taskID)
fn withTroubleshoot(troubleshoot)
fn withUseTemplates(useTemplates)
fn withUseTemplatesMixin(useTemplates)
obj spec.configuration
fn withClusters(clusters)
fn withClustersMixin(clusters)
fn withFiles(files)
fn withFilesMixin(files)
fn withProfiles(profiles)
fn withProfilesMixin(profiles)
fn withQuotas(quotas)
fn withQuotasMixin(quotas)
fn withSettings(settings)
fn withSettingsMixin(settings)
fn withUsers(users)
fn withUsersMixin(users)
obj spec.configuration.clusters
fn withFiles(files)
fn withFilesMixin(files)
fn withInsecure(insecure)
fn withName(name)
fn withSecure(secure)
fn withSettings(settings)
fn withSettingsMixin(settings)
obj spec.configuration.clusters.layout
fn withReplicas(replicas)
fn withReplicasCount(replicasCount)
fn withReplicasMixin(replicas)
fn withShards(shards)
fn withShardsCount(shardsCount)
fn withShardsMixin(shards)
fn withType(type)
obj spec.configuration.clusters.layout.replicas
fn withFiles(files)
fn withFilesMixin(files)
fn withName(name)
fn withSettings(settings)
fn withSettingsMixin(settings)
fn withShards(shards)
fn withShardsCount(shardsCount)
fn withShardsMixin(shards)
obj spec.configuration.clusters.layout.replicas.shards
fn withFiles(files)
fn withFilesMixin(files)
fn withHttpPort(httpPort)
fn withHttpsPort(httpsPort)
fn withInsecure(insecure)
fn withInterserverHTTPPort(interserverHTTPPort)
fn withName(name)
fn withSecure(secure)
fn withSettings(settings)
fn withSettingsMixin(settings)
fn withTcpPort(tcpPort)
fn withTlsPort(tlsPort)
obj spec.configuration.clusters.layout.replicas.shards.templates
fn withClusterServiceTemplate(clusterServiceTemplate)
fn withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
fn withHostTemplate(hostTemplate)
fn withLogVolumeClaimTemplate(logVolumeClaimTemplate)
fn withPodTemplate(podTemplate)
fn withReplicaServiceTemplate(replicaServiceTemplate)
fn withServiceTemplate(serviceTemplate)
fn withShardServiceTemplate(shardServiceTemplate)
fn withVolumeClaimTemplate(volumeClaimTemplate)
obj spec.configuration.clusters.layout.replicas.templates
fn withClusterServiceTemplate(clusterServiceTemplate)
fn withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
fn withHostTemplate(hostTemplate)
fn withLogVolumeClaimTemplate(logVolumeClaimTemplate)
fn withPodTemplate(podTemplate)
fn withReplicaServiceTemplate(replicaServiceTemplate)
fn withServiceTemplate(serviceTemplate)
fn withShardServiceTemplate(shardServiceTemplate)
fn withVolumeClaimTemplate(volumeClaimTemplate)
obj spec.configuration.clusters.layout.shards
fn withDefinitionType(definitionType)
fn withFiles(files)
fn withFilesMixin(files)
fn withInternalReplication(internalReplication)
fn withName(name)
fn withReplicas(replicas)
fn withReplicasCount(replicasCount)
fn withReplicasMixin(replicas)
fn withSettings(settings)
fn withSettingsMixin(settings)
fn withWeight(weight)
obj spec.configuration.clusters.layout.shards.replicas
fn withFiles(files)
fn withFilesMixin(files)
fn withHttpPort(httpPort)
fn withHttpsPort(httpsPort)
fn withInsecure(insecure)
fn withInterserverHTTPPort(interserverHTTPPort)
fn withName(name)
fn withSecure(secure)
fn withSettings(settings)
fn withSettingsMixin(settings)
fn withTcpPort(tcpPort)
fn withTlsPort(tlsPort)
obj spec.configuration.clusters.layout.shards.replicas.templates
fn withClusterServiceTemplate(clusterServiceTemplate)
fn withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
fn withHostTemplate(hostTemplate)
fn withLogVolumeClaimTemplate(logVolumeClaimTemplate)
fn withPodTemplate(podTemplate)
fn withReplicaServiceTemplate(replicaServiceTemplate)
fn withServiceTemplate(serviceTemplate)
fn withShardServiceTemplate(shardServiceTemplate)
fn withVolumeClaimTemplate(volumeClaimTemplate)
obj spec.configuration.clusters.layout.shards.templates
fn withClusterServiceTemplate(clusterServiceTemplate)
fn withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
fn withHostTemplate(hostTemplate)
fn withLogVolumeClaimTemplate(logVolumeClaimTemplate)
fn withPodTemplate(podTemplate)
fn withReplicaServiceTemplate(replicaServiceTemplate)
fn withServiceTemplate(serviceTemplate)
fn withShardServiceTemplate(shardServiceTemplate)
fn withVolumeClaimTemplate(volumeClaimTemplate)
obj spec.configuration.clusters.schemaPolicy
obj spec.configuration.clusters.secret
obj spec.configuration.clusters.templates
fn withClusterServiceTemplate(clusterServiceTemplate)
fn withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
fn withHostTemplate(hostTemplate)
fn withLogVolumeClaimTemplate(logVolumeClaimTemplate)
fn withPodTemplate(podTemplate)
fn withReplicaServiceTemplate(replicaServiceTemplate)
fn withServiceTemplate(serviceTemplate)
fn withShardServiceTemplate(shardServiceTemplate)
fn withVolumeClaimTemplate(volumeClaimTemplate)
obj spec.configuration.clusters.zookeeper
obj spec.configuration.zookeeper
obj spec.defaults
fn withReplicasUseFQDN(replicasUseFQDN)
obj spec.defaults.distributedDDL
obj spec.defaults.storageManagement
obj spec.defaults.templates
fn withClusterServiceTemplate(clusterServiceTemplate)
fn withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
fn withHostTemplate(hostTemplate)
fn withLogVolumeClaimTemplate(logVolumeClaimTemplate)
fn withPodTemplate(podTemplate)
fn withReplicaServiceTemplate(replicaServiceTemplate)
fn withServiceTemplate(serviceTemplate)
fn withShardServiceTemplate(shardServiceTemplate)
fn withVolumeClaimTemplate(volumeClaimTemplate)
obj spec.reconciling
obj spec.templates
fn withHostTemplates(hostTemplates)
fn withHostTemplatesMixin(hostTemplates)
fn withPodTemplates(podTemplates)
fn withPodTemplatesMixin(podTemplates)
fn withServiceTemplates(serviceTemplates)
fn withServiceTemplatesMixin(serviceTemplates)
fn withVolumeClaimTemplates(volumeClaimTemplates)
fn withVolumeClaimTemplatesMixin(volumeClaimTemplates)
obj spec.templates.hostTemplates
fn withName(name)
fn withPortDistribution(portDistribution)
fn withPortDistributionMixin(portDistribution)
obj spec.templates.hostTemplates.portDistribution
obj spec.templates.hostTemplates.spec
fn withFiles(files)
fn withFilesMixin(files)
fn withHttpPort(httpPort)
fn withHttpsPort(httpsPort)
fn withInsecure(insecure)
fn withInterserverHTTPPort(interserverHTTPPort)
fn withName(name)
fn withSecure(secure)
fn withSettings(settings)
fn withSettingsMixin(settings)
fn withTcpPort(tcpPort)
fn withTlsPort(tlsPort)
obj spec.templates.hostTemplates.spec.templates
fn withClusterServiceTemplate(clusterServiceTemplate)
fn withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
fn withHostTemplate(hostTemplate)
fn withLogVolumeClaimTemplate(logVolumeClaimTemplate)
fn withPodTemplate(podTemplate)
fn withReplicaServiceTemplate(replicaServiceTemplate)
fn withServiceTemplate(serviceTemplate)
fn withShardServiceTemplate(shardServiceTemplate)
fn withVolumeClaimTemplate(volumeClaimTemplate)
obj spec.templates.podTemplates
fn withDistribution(distribution)
fn withGenerateName(generateName)
fn withMetadata(metadata)
fn withMetadataMixin(metadata)
fn withName(name)
fn withPodDistribution(podDistribution)
fn withPodDistributionMixin(podDistribution)
fn withSpec(spec)
fn withSpecMixin(spec)
obj spec.templates.podTemplates.podDistribution
obj spec.templates.podTemplates.zone
obj spec.templates.serviceTemplates
obj spec.templates.volumeClaimTemplates
obj spec.templating
obj spec.useTemplates
Fields
fn new
new(name)
new returns an instance of ClickHouseInstallation
obj metadata
"ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create."
fn metadata.withAnnotations
withAnnotations(annotations)
"Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations"
fn metadata.withAnnotationsMixin
withAnnotationsMixin(annotations)
"Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations"
Note: This function appends passed data to existing values
fn metadata.withClusterName
withClusterName(clusterName)
"The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request."
fn metadata.withCreationTimestamp
withCreationTimestamp(creationTimestamp)
"Time is a wrapper around time.Time which supports correct marshaling to YAML and JSON. Wrappers are provided for many of the factory methods that the time package offers."
fn metadata.withDeletionGracePeriodSeconds
withDeletionGracePeriodSeconds(deletionGracePeriodSeconds)
"Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only."
fn metadata.withDeletionTimestamp
withDeletionTimestamp(deletionTimestamp)
"Time is a wrapper around time.Time which supports correct marshaling to YAML and JSON. Wrappers are provided for many of the factory methods that the time package offers."
fn metadata.withFinalizers
withFinalizers(finalizers)
"Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. Finalizers may be processed and removed in any order. Order is NOT enforced because it introduces significant risk of stuck finalizers. finalizers is a shared field, any actor with permission can reorder it. If the finalizer list is processed in order, then this can lead to a situation in which the component responsible for the first finalizer in the list is waiting for a signal (field value, external system, or other) produced by a component responsible for a finalizer later in the list, resulting in a deadlock. Without enforced ordering finalizers are free to order amongst themselves and are not vulnerable to ordering changes in the list."
fn metadata.withFinalizersMixin
withFinalizersMixin(finalizers)
"Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. Finalizers may be processed and removed in any order. Order is NOT enforced because it introduces significant risk of stuck finalizers. finalizers is a shared field, any actor with permission can reorder it. If the finalizer list is processed in order, then this can lead to a situation in which the component responsible for the first finalizer in the list is waiting for a signal (field value, external system, or other) produced by a component responsible for a finalizer later in the list, resulting in a deadlock. Without enforced ordering finalizers are free to order amongst themselves and are not vulnerable to ordering changes in the list."
Note: This function appends passed data to existing values
fn metadata.withGenerateName
withGenerateName(generateName)
"GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).\n\nApplied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#idempotency"
fn metadata.withGeneration
withGeneration(generation)
"A sequence number representing a specific generation of the desired state. Populated by the system. Read-only."
fn metadata.withLabels
withLabels(labels)
"Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels"
fn metadata.withLabelsMixin
withLabelsMixin(labels)
"Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels"
Note: This function appends passed data to existing values
fn metadata.withName
withName(name)
"Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names"
fn metadata.withNamespace
withNamespace(namespace)
"Namespace defines the space within which each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces"
fn metadata.withOwnerReferences
withOwnerReferences(ownerReferences)
"List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller."
fn metadata.withOwnerReferencesMixin
withOwnerReferencesMixin(ownerReferences)
"List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller."
Note: This function appends passed data to existing values
fn metadata.withResourceVersion
withResourceVersion(resourceVersion)
"An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency"
fn metadata.withSelfLink
withSelfLink(selfLink)
"SelfLink is a URL representing this object. Populated by the system. Read-only.\n\nDEPRECATED Kubernetes will stop propagating this field in 1.20 release and the field is planned to be removed in 1.21 release."
fn metadata.withUid
withUid(uid)
"UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/identifiers#uids"
obj spec
"Specification of the desired behavior of one or more ClickHouse clusters\nMore info: https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md\n"
fn spec.withNamespaceDomainPattern
withNamespaceDomainPattern(namespaceDomainPattern)
"Custom domain pattern which will be used for DNS names of Service
or Pod
.\nTypical use scenario - custom cluster domain in Kubernetes cluster\nExample: %s.svc.my.test\n"
fn spec.withRestart
withRestart(restart)
"In case 'RollingUpdate' specified, the operator will always restart ClickHouse pods during reconcile.\nThis options is used in rare cases when force restart is required and is typically removed after the use in order to avoid unneeded restarts.\n"
fn spec.withStop
withStop(stop)
"Allows to stop all ClickHouse clusters defined in a CHI.\nWorks as the following:\n - When stop
is 1
operator sets Replicas: 0
in each StatefulSet. Thie leads to having all Pods
and Service
deleted. All PVCs are kept intact.\n - When stop
is 0
operator sets Replicas: 1
and Pod
s and Service
s will created again and all retained PVCs will be attached to Pod
s.\n"
fn spec.withTaskID
withTaskID(taskID)
"Allows to define custom taskID for CHI update and watch status of this update execution.\nDisplayed in all .status.taskID* fields.\nBy default (if not filled) every update of CHI manifest will generate random taskID\n"
fn spec.withTroubleshoot
withTroubleshoot(troubleshoot)
"Allows to troubleshoot Pods during CrashLoopBack state.\nThis may happen when wrong configuration applied, in this case clickhouse-server
wouldn't start.\nCommand within ClickHouse container is modified with sleep
in order to avoid quick restarts\nand give time to troubleshoot via CLI.\nLiveness and Readiness probes are disabled as well.\n"
fn spec.withUseTemplates
withUseTemplates(useTemplates)
"list of ClickHouseInstallationTemplate
(chit) resource names which will merge with current Chi
manifest during render Kubernetes resources to create related ClickHouse clusters"
fn spec.withUseTemplatesMixin
withUseTemplatesMixin(useTemplates)
"list of ClickHouseInstallationTemplate
(chit) resource names which will merge with current Chi
manifest during render Kubernetes resources to create related ClickHouse clusters"
Note: This function appends passed data to existing values
obj spec.configuration
"allows configure multiple aspects and behavior for clickhouse-server
instance and also allows describe multiple clickhouse-server
clusters inside one chi
resource"
fn spec.configuration.withClusters
withClusters(clusters)
"describes ClickHouse clusters layout and allows change settings on cluster-level, shard-level and replica-level\nevery cluster is a set of StatefulSet, one StatefulSet contains only one Pod with clickhouse-server
\nall Pods will rendered in /etc/clickhouse-server/config.d/chop-generated-remote_servers.xml
\nClusters will use for Distributed table engine, more details: https://clickhouse.tech/docs/en/engines/table-engines/special/distributed/\nIf cluster
contains zookeeper settings (could be inherited from top chi
level), when you can create *ReplicatedMergeTree tables\n"
fn spec.configuration.withClustersMixin
withClustersMixin(clusters)
"describes ClickHouse clusters layout and allows change settings on cluster-level, shard-level and replica-level\nevery cluster is a set of StatefulSet, one StatefulSet contains only one Pod with clickhouse-server
\nall Pods will rendered in /etc/clickhouse-server/config.d/chop-generated-remote_servers.xml
\nClusters will use for Distributed table engine, more details: https://clickhouse.tech/docs/en/engines/table-engines/special/distributed/\nIf cluster
contains zookeeper settings (could be inherited from top chi
level), when you can create *ReplicatedMergeTree tables\n"
Note: This function appends passed data to existing values
fn spec.configuration.withFiles
withFiles(files)
"allows define content of any setting file inside each Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\nevery key in this object is the file name\nevery value in this object is the file content\nyou can use !!binary |
and base64 for binary files, see details here https://yaml.org/type/binary.html\neach key could contains prefix like USERS, COMMON, HOST or config.d, users.d, cond.d, wrong prefixes will ignored, subfolders also will ignored\nMore details: https://github.com/Altinity/clickhouse-operator/blob/master/docs/chi-examples/05-settings-05-files-nested.yaml\n"
fn spec.configuration.withFilesMixin
withFilesMixin(files)
"allows define content of any setting file inside each Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\nevery key in this object is the file name\nevery value in this object is the file content\nyou can use !!binary |
and base64 for binary files, see details here https://yaml.org/type/binary.html\neach key could contains prefix like USERS, COMMON, HOST or config.d, users.d, cond.d, wrong prefixes will ignored, subfolders also will ignored\nMore details: https://github.com/Altinity/clickhouse-operator/blob/master/docs/chi-examples/05-settings-05-files-nested.yaml\n"
Note: This function appends passed data to existing values
fn spec.configuration.withProfiles
withProfiles(profiles)
"allows configure Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/users.d/
\nyou can configure any aspect of settings profile\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings-profiles/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationprofiles\n"
fn spec.configuration.withProfilesMixin
withProfilesMixin(profiles)
"allows configure Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/users.d/
\nyou can configure any aspect of settings profile\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings-profiles/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationprofiles\n"
Note: This function appends passed data to existing values
fn spec.configuration.withQuotas
withQuotas(quotas)
"allows configure Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/users.d/
\nyou can configure any aspect of resource quotas\nMore details: https://clickhouse.tech/docs/en/operations/quotas/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationquotas\n"
fn spec.configuration.withQuotasMixin
withQuotasMixin(quotas)
"allows configure Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/users.d/
\nyou can configure any aspect of resource quotas\nMore details: https://clickhouse.tech/docs/en/operations/quotas/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationquotas\n"
Note: This function appends passed data to existing values
fn spec.configuration.withSettings
withSettings(settings)
"allows configure clickhouse-server
settings inside Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationsettings\n"
fn spec.configuration.withSettingsMixin
withSettingsMixin(settings)
"allows configure clickhouse-server
settings inside Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationsettings\n"
Note: This function appends passed data to existing values
fn spec.configuration.withUsers
withUsers(users)
"allows configure Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/users.d/
\nyou can configure password hashed, authorization restrictions, database level security row filters etc.\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings-users/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationusers\n"
fn spec.configuration.withUsersMixin
withUsersMixin(users)
"allows configure Pod
during generate ConfigMap
which will mount in /etc/clickhouse-server/users.d/
\nyou can configure password hashed, authorization restrictions, database level security row filters etc.\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings-users/\nYour yaml code will convert to XML, see examples https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specconfigurationusers\n"
Note: This function appends passed data to existing values
obj spec.configuration.clusters
"describes ClickHouse clusters layout and allows change settings on cluster-level, shard-level and replica-level\nevery cluster is a set of StatefulSet, one StatefulSet contains only one Pod with clickhouse-server
\nall Pods will rendered in /etc/clickhouse-server/config.d/chop-generated-remote_servers.xml
\nClusters will use for Distributed table engine, more details: https://clickhouse.tech/docs/en/engines/table-engines/special/distributed/\nIf cluster
contains zookeeper settings (could be inherited from top chi
level), when you can create *ReplicatedMergeTree tables\n"
fn spec.configuration.clusters.withFiles
withFiles(files)
"optional, allows define content of any setting file inside each Pod
on current cluster during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
\n"
fn spec.configuration.clusters.withFilesMixin
withFilesMixin(files)
"optional, allows define content of any setting file inside each Pod
on current cluster during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.withInsecure
withInsecure(insecure)
"optional, open insecure ports for cluster, defaults to \"yes\
fn spec.configuration.clusters.withName
withName(name)
"cluster name, used to identify set of ClickHouse servers and wide used during generate names of related Kubernetes resources"
fn spec.configuration.clusters.withSecure
withSecure(secure)
"optional, open secure ports for cluster"
fn spec.configuration.clusters.withSettings
withSettings(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one cluster during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
\noverride top-level chi.spec.configuration.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
fn spec.configuration.clusters.withSettingsMixin
withSettingsMixin(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one cluster during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
\noverride top-level chi.spec.configuration.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
Note: This function appends passed data to existing values
obj spec.configuration.clusters.layout
"describe current cluster layout, how much shards in cluster, how much replica in shard\nallows override settings on each shard and replica separatelly\n"
fn spec.configuration.clusters.layout.withReplicas
withReplicas(replicas)
"optional, allows override top-level chi.spec.configuration
and cluster-level chi.spec.configuration.clusters
configuration for each replica and each shard relates to selected replica, use it only if you fully understand what you do"
fn spec.configuration.clusters.layout.withReplicasCount
withReplicasCount(replicasCount)
"how much replicas in each shards for current ClickHouse cluster will run in Kubernetes, each replica is a separate StatefulSet
which contains only one Pod
with clickhouse-server
instance, every shard contains 1 replica by default"
fn spec.configuration.clusters.layout.withReplicasMixin
withReplicasMixin(replicas)
"optional, allows override top-level chi.spec.configuration
and cluster-level chi.spec.configuration.clusters
configuration for each replica and each shard relates to selected replica, use it only if you fully understand what you do"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.withShards
withShards(shards)
"optional, allows override top-level chi.spec.configuration
, cluster-level chi.spec.configuration.clusters
settings for each shard separately, use it only if you fully understand what you do"
fn spec.configuration.clusters.layout.withShardsCount
withShardsCount(shardsCount)
"how much shards for current ClickHouse cluster will run in Kubernetes, each shard contains shared-nothing part of data and contains set of replicas, cluster contains 1 shard by default"
fn spec.configuration.clusters.layout.withShardsMixin
withShardsMixin(shards)
"optional, allows override top-level chi.spec.configuration
, cluster-level chi.spec.configuration.clusters
settings for each shard separately, use it only if you fully understand what you do"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.withType
withType(type)
"DEPRECATED - to be removed soon"
obj spec.configuration.clusters.layout.replicas
"optional, allows override top-level chi.spec.configuration
and cluster-level chi.spec.configuration.clusters
configuration for each replica and each shard relates to selected replica, use it only if you fully understand what you do"
fn spec.configuration.clusters.layout.replicas.withFiles
withFiles(files)
"optional, allows define content of any setting file inside each Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
and cluster-level chi.spec.configuration.clusters.files
, will ignore if chi.spec.configuration.clusters.layout.shards
presents\n"
fn spec.configuration.clusters.layout.replicas.withFilesMixin
withFilesMixin(files)
"optional, allows define content of any setting file inside each Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
and cluster-level chi.spec.configuration.clusters.files
, will ignore if chi.spec.configuration.clusters.layout.shards
presents\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.replicas.withName
withName(name)
"optional, by default replica name is generated, but you can override it and setup custom name"
fn spec.configuration.clusters.layout.replicas.withSettings
withSettings(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\noverride top-level chi.spec.configuration.settings
, cluster-level chi.spec.configuration.clusters.settings
and will ignore if shard-level chi.spec.configuration.clusters.layout.shards
present\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
fn spec.configuration.clusters.layout.replicas.withSettingsMixin
withSettingsMixin(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\noverride top-level chi.spec.configuration.settings
, cluster-level chi.spec.configuration.clusters.settings
and will ignore if shard-level chi.spec.configuration.clusters.layout.shards
present\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.replicas.withShards
withShards(shards)
"optional, list of shards related to current replica, will ignore if chi.spec.configuration.clusters.layout.shards
presents"
fn spec.configuration.clusters.layout.replicas.withShardsCount
withShardsCount(shardsCount)
"optional, count of shards related to current replica, you can override each shard behavior on low-level chi.spec.configuration.clusters.layout.replicas.shards
"
fn spec.configuration.clusters.layout.replicas.withShardsMixin
withShardsMixin(shards)
"optional, list of shards related to current replica, will ignore if chi.spec.configuration.clusters.layout.shards
presents"
Note: This function appends passed data to existing values
obj spec.configuration.clusters.layout.replicas.shards
"optional, list of shards related to current replica, will ignore if chi.spec.configuration.clusters.layout.shards
presents"
fn spec.configuration.clusters.layout.replicas.shards.withFiles
withFiles(files)
"optional, allows define content of any setting file inside each Pod
only in one shard related to current replica during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
and cluster-level chi.spec.configuration.clusters.files
, will ignore if chi.spec.configuration.clusters.layout.shards
presents\n"
fn spec.configuration.clusters.layout.replicas.shards.withFilesMixin
withFilesMixin(files)
"optional, allows define content of any setting file inside each Pod
only in one shard related to current replica during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
and cluster-level chi.spec.configuration.clusters.files
, will ignore if chi.spec.configuration.clusters.layout.shards
presents\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.replicas.shards.withHttpPort
withHttpPort(httpPort)
"optional, setup Pod.spec.containers.ports
with name http
for selected shard, override chi.spec.templates.hostTemplates.spec.httpPort
\nallows connect to clickhouse-server
via HTTP protocol via kubernetes Service
\n"
fn spec.configuration.clusters.layout.replicas.shards.withHttpsPort
withHttpsPort(httpsPort)
fn spec.configuration.clusters.layout.replicas.shards.withInsecure
withInsecure(insecure)
"optional, open insecure ports for cluster, defaults to \"yes\"\n"
fn spec.configuration.clusters.layout.replicas.shards.withInterserverHTTPPort
withInterserverHTTPPort(interserverHTTPPort)
"optional, setup Pod.spec.containers.ports
with name interserver
for selected shard, override chi.spec.templates.hostTemplates.spec.interserverHTTPPort
\nallows connect between replicas inside same shard during fetch replicated data parts HTTP protocol\n"
fn spec.configuration.clusters.layout.replicas.shards.withName
withName(name)
"optional, by default shard name is generated, but you can override it and setup custom name"
fn spec.configuration.clusters.layout.replicas.shards.withSecure
withSecure(secure)
"optional, open secure ports\n"
fn spec.configuration.clusters.layout.replicas.shards.withSettings
withSettings(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one shard related to current replica during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\noverride top-level chi.spec.configuration.settings
, cluster-level chi.spec.configuration.clusters.settings
and replica-level chi.spec.configuration.clusters.layout.replicas.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
fn spec.configuration.clusters.layout.replicas.shards.withSettingsMixin
withSettingsMixin(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one shard related to current replica during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\noverride top-level chi.spec.configuration.settings
, cluster-level chi.spec.configuration.clusters.settings
and replica-level chi.spec.configuration.clusters.layout.replicas.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.replicas.shards.withTcpPort
withTcpPort(tcpPort)
"optional, setup Pod.spec.containers.ports
with name tcp
for selected shard, override chi.spec.templates.hostTemplates.spec.tcpPort
\nallows connect to clickhouse-server
via TCP Native protocol via kubernetes Service
\n"
fn spec.configuration.clusters.layout.replicas.shards.withTlsPort
withTlsPort(tlsPort)
obj spec.configuration.clusters.layout.replicas.shards.templates
"optional, configuration of the templates names which will use for generate Kubernetes resources according to selected replica\noverride top-level chi.spec.configuration.templates
, cluster-level chi.spec.configuration.clusters.templates
, replica-level chi.spec.configuration.clusters.layout.replicas.templates
\n"
fn spec.configuration.clusters.layout.replicas.shards.templates.withClusterServiceTemplate
withClusterServiceTemplate(clusterServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.shards.templates.withDataVolumeClaimTemplate
withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse data directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.shards.templates.withHostTemplate
withHostTemplate(hostTemplate)
"optional, template name from chi.spec.templates.hostTemplates, which will apply to configure every clickhouse-server
instance during render ConfigMap resources which will mount into Pod
"
fn spec.configuration.clusters.layout.replicas.shards.templates.withLogVolumeClaimTemplate
withLogVolumeClaimTemplate(logVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse log directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.shards.templates.withPodTemplate
withPodTemplate(podTemplate)
"optional, template name from chi.spec.templates.podTemplates, allows customization each Pod
resource during render and reconcile each StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.shards.templates.withReplicaServiceTemplate
withReplicaServiceTemplate(replicaServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each replica inside each shard inside each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.shards.templates.withServiceTemplate
withServiceTemplate(serviceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for one Service
resource which will created by clickhouse-operator
which cover all clusters in whole chi
resource"
fn spec.configuration.clusters.layout.replicas.shards.templates.withShardServiceTemplate
withShardServiceTemplate(shardServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each shard inside clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.shards.templates.withVolumeClaimTemplate
withVolumeClaimTemplate(volumeClaimTemplate)
"DEPRECATED! VolumeClaimTemplate is deprecated in favor of DataVolumeClaimTemplate and LogVolumeClaimTemplate"
obj spec.configuration.clusters.layout.replicas.templates
"optional, configuration of the templates names which will use for generate Kubernetes resources according to selected replica\noverride top-level chi.spec.configuration.templates
, cluster-level chi.spec.configuration.clusters.templates
\n"
fn spec.configuration.clusters.layout.replicas.templates.withClusterServiceTemplate
withClusterServiceTemplate(clusterServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.templates.withDataVolumeClaimTemplate
withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse data directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.templates.withHostTemplate
withHostTemplate(hostTemplate)
"optional, template name from chi.spec.templates.hostTemplates, which will apply to configure every clickhouse-server
instance during render ConfigMap resources which will mount into Pod
"
fn spec.configuration.clusters.layout.replicas.templates.withLogVolumeClaimTemplate
withLogVolumeClaimTemplate(logVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse log directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.templates.withPodTemplate
withPodTemplate(podTemplate)
"optional, template name from chi.spec.templates.podTemplates, allows customization each Pod
resource during render and reconcile each StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.templates.withReplicaServiceTemplate
withReplicaServiceTemplate(replicaServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each replica inside each shard inside each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.templates.withServiceTemplate
withServiceTemplate(serviceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for one Service
resource which will created by clickhouse-operator
which cover all clusters in whole chi
resource"
fn spec.configuration.clusters.layout.replicas.templates.withShardServiceTemplate
withShardServiceTemplate(shardServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each shard inside clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.replicas.templates.withVolumeClaimTemplate
withVolumeClaimTemplate(volumeClaimTemplate)
"DEPRECATED! VolumeClaimTemplate is deprecated in favor of DataVolumeClaimTemplate and LogVolumeClaimTemplate"
obj spec.configuration.clusters.layout.shards
"optional, allows override top-level chi.spec.configuration
, cluster-level chi.spec.configuration.clusters
settings for each shard separately, use it only if you fully understand what you do"
fn spec.configuration.clusters.layout.shards.withDefinitionType
withDefinitionType(definitionType)
"DEPRECATED - to be removed soon"
fn spec.configuration.clusters.layout.shards.withFiles
withFiles(files)
"optional, allows define content of any setting file inside each Pod
only in one shard during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
and cluster-level chi.spec.configuration.clusters.files
\n"
fn spec.configuration.clusters.layout.shards.withFilesMixin
withFilesMixin(files)
"optional, allows define content of any setting file inside each Pod
only in one shard during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
and cluster-level chi.spec.configuration.clusters.files
\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.shards.withInternalReplication
withInternalReplication(internalReplication)
"optional, true
by default when chi.spec.configuration.clusters[].layout.ReplicaCount
> 1 and 0 otherwise\nallows setup Distributed
engine for insert only in one live replica and other replicas will download inserted data during replication,\nwill apply in
fn spec.configuration.clusters.layout.shards.withName
withName(name)
"optional, by default shard name is generated, but you can override it and setup custom name"
fn spec.configuration.clusters.layout.shards.withReplicas
withReplicas(replicas)
"optional, allows override behavior for selected replicas from cluster-level chi.spec.configuration.clusters
and shard-level chi.spec.configuration.clusters.layout.shards
\n"
fn spec.configuration.clusters.layout.shards.withReplicasCount
withReplicasCount(replicasCount)
"optional, how much replicas in selected shard for selected ClickHouse cluster will run in Kubernetes, each replica is a separate StatefulSet
which contains only one Pod
with clickhouse-server
instance,\nshard contains 1 replica by default\noverride cluster-level chi.spec.configuration.clusters.layout.replicasCount
\n"
fn spec.configuration.clusters.layout.shards.withReplicasMixin
withReplicasMixin(replicas)
"optional, allows override behavior for selected replicas from cluster-level chi.spec.configuration.clusters
and shard-level chi.spec.configuration.clusters.layout.shards
\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.shards.withSettings
withSettings(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one shard during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
\noverride top-level chi.spec.configuration.settings
and cluster-level chi.spec.configuration.clusters.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
fn spec.configuration.clusters.layout.shards.withSettingsMixin
withSettingsMixin(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one shard during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
\noverride top-level chi.spec.configuration.settings
and cluster-level chi.spec.configuration.clusters.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.shards.withWeight
withWeight(weight)
"optional, 1 by default, allows setup shard Distributed
engine,\nwill apply in
obj spec.configuration.clusters.layout.shards.replicas
"optional, allows override behavior for selected replicas from cluster-level chi.spec.configuration.clusters
and shard-level chi.spec.configuration.clusters.layout.shards
\n"
fn spec.configuration.clusters.layout.shards.replicas.withFiles
withFiles(files)
"optional, allows define content of any setting file inside Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
, cluster-level chi.spec.configuration.clusters.files
and shard-level chi.spec.configuration.clusters.layout.shards.files
\n"
fn spec.configuration.clusters.layout.shards.replicas.withFilesMixin
withFilesMixin(files)
"optional, allows define content of any setting file inside Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\noverride top-level chi.spec.configuration.files
, cluster-level chi.spec.configuration.clusters.files
and shard-level chi.spec.configuration.clusters.layout.shards.files
\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.shards.replicas.withHttpPort
withHttpPort(httpPort)
"optional, setup Pod.spec.containers.ports
with name http
for selected replica, override chi.spec.templates.hostTemplates.spec.httpPort
\nallows connect to clickhouse-server
via HTTP protocol via kubernetes Service
\n"
fn spec.configuration.clusters.layout.shards.replicas.withHttpsPort
withHttpsPort(httpsPort)
fn spec.configuration.clusters.layout.shards.replicas.withInsecure
withInsecure(insecure)
"optional, open insecure ports for cluster, defaults to \"yes\"\n"
fn spec.configuration.clusters.layout.shards.replicas.withInterserverHTTPPort
withInterserverHTTPPort(interserverHTTPPort)
"optional, setup Pod.spec.containers.ports
with name interserver
for selected replica, override chi.spec.templates.hostTemplates.spec.interserverHTTPPort
\nallows connect between replicas inside same shard during fetch replicated data parts HTTP protocol\n"
fn spec.configuration.clusters.layout.shards.replicas.withName
withName(name)
"optional, by default replica name is generated, but you can override it and setup custom name"
fn spec.configuration.clusters.layout.shards.replicas.withSecure
withSecure(secure)
"optional, open secure ports\n"
fn spec.configuration.clusters.layout.shards.replicas.withSettings
withSettings(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\noverride top-level chi.spec.configuration.settings
, cluster-level chi.spec.configuration.clusters.settings
and shard-level chi.spec.configuration.clusters.layout.shards.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
fn spec.configuration.clusters.layout.shards.replicas.withSettingsMixin
withSettingsMixin(settings)
"optional, allows configure clickhouse-server
settings inside Pod
only in one replica during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\noverride top-level chi.spec.configuration.settings
, cluster-level chi.spec.configuration.clusters.settings
and shard-level chi.spec.configuration.clusters.layout.shards.settings
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.layout.shards.replicas.withTcpPort
withTcpPort(tcpPort)
"optional, setup Pod.spec.containers.ports
with name tcp
for selected replica, override chi.spec.templates.hostTemplates.spec.tcpPort
\nallows connect to clickhouse-server
via TCP Native protocol via kubernetes Service
\n"
fn spec.configuration.clusters.layout.shards.replicas.withTlsPort
withTlsPort(tlsPort)
obj spec.configuration.clusters.layout.shards.replicas.templates
"optional, configuration of the templates names which will use for generate Kubernetes resources according to selected replica\noverride top-level chi.spec.configuration.templates
, cluster-level chi.spec.configuration.clusters.templates
and shard-level chi.spec.configuration.clusters.layout.shards.templates
\n"
fn spec.configuration.clusters.layout.shards.replicas.templates.withClusterServiceTemplate
withClusterServiceTemplate(clusterServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.replicas.templates.withDataVolumeClaimTemplate
withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse data directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.replicas.templates.withHostTemplate
withHostTemplate(hostTemplate)
"optional, template name from chi.spec.templates.hostTemplates, which will apply to configure every clickhouse-server
instance during render ConfigMap resources which will mount into Pod
"
fn spec.configuration.clusters.layout.shards.replicas.templates.withLogVolumeClaimTemplate
withLogVolumeClaimTemplate(logVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse log directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.replicas.templates.withPodTemplate
withPodTemplate(podTemplate)
"optional, template name from chi.spec.templates.podTemplates, allows customization each Pod
resource during render and reconcile each StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.replicas.templates.withReplicaServiceTemplate
withReplicaServiceTemplate(replicaServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each replica inside each shard inside each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.replicas.templates.withServiceTemplate
withServiceTemplate(serviceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for one Service
resource which will created by clickhouse-operator
which cover all clusters in whole chi
resource"
fn spec.configuration.clusters.layout.shards.replicas.templates.withShardServiceTemplate
withShardServiceTemplate(shardServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each shard inside clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.replicas.templates.withVolumeClaimTemplate
withVolumeClaimTemplate(volumeClaimTemplate)
"DEPRECATED! VolumeClaimTemplate is deprecated in favor of DataVolumeClaimTemplate and LogVolumeClaimTemplate"
obj spec.configuration.clusters.layout.shards.templates
"optional, configuration of the templates names which will use for generate Kubernetes resources according to selected shard\noverride top-level chi.spec.configuration.templates
and cluster-level chi.spec.configuration.clusters.templates
\n"
fn spec.configuration.clusters.layout.shards.templates.withClusterServiceTemplate
withClusterServiceTemplate(clusterServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.templates.withDataVolumeClaimTemplate
withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse data directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.templates.withHostTemplate
withHostTemplate(hostTemplate)
"optional, template name from chi.spec.templates.hostTemplates, which will apply to configure every clickhouse-server
instance during render ConfigMap resources which will mount into Pod
"
fn spec.configuration.clusters.layout.shards.templates.withLogVolumeClaimTemplate
withLogVolumeClaimTemplate(logVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse log directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.templates.withPodTemplate
withPodTemplate(podTemplate)
"optional, template name from chi.spec.templates.podTemplates, allows customization each Pod
resource during render and reconcile each StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.templates.withReplicaServiceTemplate
withReplicaServiceTemplate(replicaServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each replica inside each shard inside each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.templates.withServiceTemplate
withServiceTemplate(serviceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for one Service
resource which will created by clickhouse-operator
which cover all clusters in whole chi
resource"
fn spec.configuration.clusters.layout.shards.templates.withShardServiceTemplate
withShardServiceTemplate(shardServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each shard inside clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.layout.shards.templates.withVolumeClaimTemplate
withVolumeClaimTemplate(volumeClaimTemplate)
"DEPRECATED! VolumeClaimTemplate is deprecated in favor of DataVolumeClaimTemplate and LogVolumeClaimTemplate"
obj spec.configuration.clusters.schemaPolicy
"describes how schema is propagated within replicas and shards\n"
fn spec.configuration.clusters.schemaPolicy.withReplica
withReplica(replica)
"how schema is propagated within a replica"
fn spec.configuration.clusters.schemaPolicy.withShard
withShard(shard)
"how schema is propagated between shards"
obj spec.configuration.clusters.secret
"optional, shared secret value to secure cluster communications"
fn spec.configuration.clusters.secret.withAuto
withAuto(auto)
"Auto-generate shared secret value to secure cluster communications"
fn spec.configuration.clusters.secret.withValue
withValue(value)
"Cluster shared secret value in plain text"
obj spec.configuration.clusters.secret.valueFrom
"Cluster shared secret source"
obj spec.configuration.clusters.secret.valueFrom.secretKeyRef
"Selects a key of a secret in the clickhouse installation namespace.\nShould not be used if value is not empty.\n"
fn spec.configuration.clusters.secret.valueFrom.secretKeyRef.withKey
withKey(key)
"The key of the secret to select from. Must be a valid secret key."
fn spec.configuration.clusters.secret.valueFrom.secretKeyRef.withName
withName(name)
"Name of the referent. More info:\nhttps://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names\n"
fn spec.configuration.clusters.secret.valueFrom.secretKeyRef.withOptional
withOptional(optional)
"Specify whether the Secret or its key must be defined"
obj spec.configuration.clusters.templates
"optional, configuration of the templates names which will use for generate Kubernetes resources according to selected cluster\noverride top-level chi.spec.configuration.templates
\n"
fn spec.configuration.clusters.templates.withClusterServiceTemplate
withClusterServiceTemplate(clusterServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.templates.withDataVolumeClaimTemplate
withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse data directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.templates.withHostTemplate
withHostTemplate(hostTemplate)
"optional, template name from chi.spec.templates.hostTemplates, which will apply to configure every clickhouse-server
instance during render ConfigMap resources which will mount into Pod
"
fn spec.configuration.clusters.templates.withLogVolumeClaimTemplate
withLogVolumeClaimTemplate(logVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse log directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.templates.withPodTemplate
withPodTemplate(podTemplate)
"optional, template name from chi.spec.templates.podTemplates, allows customization each Pod
resource during render and reconcile each StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.templates.withReplicaServiceTemplate
withReplicaServiceTemplate(replicaServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each replica inside each shard inside each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.templates.withServiceTemplate
withServiceTemplate(serviceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for one Service
resource which will created by clickhouse-operator
which cover all clusters in whole chi
resource"
fn spec.configuration.clusters.templates.withShardServiceTemplate
withShardServiceTemplate(shardServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each shard inside clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.configuration.clusters.templates.withVolumeClaimTemplate
withVolumeClaimTemplate(volumeClaimTemplate)
"DEPRECATED! VolumeClaimTemplate is deprecated in favor of DataVolumeClaimTemplate and LogVolumeClaimTemplate"
obj spec.configuration.clusters.zookeeper
"optional, allows configure Pod
only in current ClickHouse cluster, during generate ConfigMap
which will mounted in /etc/clickhouse-server/config.d/
\noverride top-level chi.spec.configuration.zookeeper
settings\n"
fn spec.configuration.clusters.zookeeper.withIdentity
withIdentity(identity)
"optional access credentials string with user:password
format used when use digest authorization in Zookeeper"
fn spec.configuration.clusters.zookeeper.withNodes
withNodes(nodes)
"describe every available zookeeper cluster node for interaction"
fn spec.configuration.clusters.zookeeper.withNodesMixin
withNodesMixin(nodes)
"describe every available zookeeper cluster node for interaction"
Note: This function appends passed data to existing values
fn spec.configuration.clusters.zookeeper.withOperation_timeout_ms
withOperation_timeout_ms(operation_timeout_ms)
"one operation timeout during Zookeeper transactions"
fn spec.configuration.clusters.zookeeper.withRoot
withRoot(root)
"optional root znode path inside zookeeper to store ClickHouse related data (replication queue or distributed DDL)"
fn spec.configuration.clusters.zookeeper.withSession_timeout_ms
withSession_timeout_ms(session_timeout_ms)
"session timeout during connect to Zookeeper"
obj spec.configuration.clusters.zookeeper.nodes
"describe every available zookeeper cluster node for interaction"
fn spec.configuration.clusters.zookeeper.nodes.withHost
withHost(host)
"dns name or ip address for Zookeeper node"
fn spec.configuration.clusters.zookeeper.nodes.withPort
withPort(port)
"TCP port which used to connect to Zookeeper node"
fn spec.configuration.clusters.zookeeper.nodes.withSecure
withSecure(secure)
"if a secure connection to Zookeeper is required"
obj spec.configuration.zookeeper
"allows configure Pod
during generate ConfigMap
which will mounted in /etc/clickhouse-server/config.d/
\nclickhouse-operator
itself doesn't manage Zookeeper, please install Zookeeper separatelly look examples on https://github.com/Altinity/clickhouse-operator/tree/master/deploy/zookeeper/\ncurrently, zookeeper (or clickhouse-keeper replacement) used for *ReplicatedMergeTree table engines and for distributed_ddl
\nMore details: https://clickhouse.tech/docs/en/operations/server-configuration-parameters/settings/#server-settings_zookeeper\n"
fn spec.configuration.zookeeper.withIdentity
withIdentity(identity)
"optional access credentials string with user:password
format used when use digest authorization in Zookeeper"
fn spec.configuration.zookeeper.withNodes
withNodes(nodes)
"describe every available zookeeper cluster node for interaction"
fn spec.configuration.zookeeper.withNodesMixin
withNodesMixin(nodes)
"describe every available zookeeper cluster node for interaction"
Note: This function appends passed data to existing values
fn spec.configuration.zookeeper.withOperation_timeout_ms
withOperation_timeout_ms(operation_timeout_ms)
"one operation timeout during Zookeeper transactions"
fn spec.configuration.zookeeper.withRoot
withRoot(root)
"optional root znode path inside zookeeper to store ClickHouse related data (replication queue or distributed DDL)"
fn spec.configuration.zookeeper.withSession_timeout_ms
withSession_timeout_ms(session_timeout_ms)
"session timeout during connect to Zookeeper"
obj spec.configuration.zookeeper.nodes
"describe every available zookeeper cluster node for interaction"
fn spec.configuration.zookeeper.nodes.withHost
withHost(host)
"dns name or ip address for Zookeeper node"
fn spec.configuration.zookeeper.nodes.withPort
withPort(port)
"TCP port which used to connect to Zookeeper node"
fn spec.configuration.zookeeper.nodes.withSecure
withSecure(secure)
"if a secure connection to Zookeeper is required"
obj spec.defaults
"define default behavior for whole ClickHouseInstallation, some behavior can be re-define on cluster, shard and replica level\nMore info: https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#specdefaults\n"
fn spec.defaults.withReplicasUseFQDN
withReplicasUseFQDN(replicasUseFQDN)
"define should replicas be specified by FQDN in <host></host>
.\nIn case of \"no\" will use short hostname and clickhouse-server will use kubernetes default suffixes for DNS lookup\n\"yes\" by default\n"
obj spec.defaults.distributedDDL
"allows change <yandex><distributed_ddl></distributed_ddl></yandex>
settings\nMore info: https://clickhouse.tech/docs/en/operations/server-configuration-parameters/settings/#server-settings-distributed_ddl\n"
fn spec.defaults.distributedDDL.withProfile
withProfile(profile)
"Settings from this profile will be used to execute DDL queries"
obj spec.defaults.storageManagement
"default storage management options"
fn spec.defaults.storageManagement.withProvisioner
withProvisioner(provisioner)
"defines PVC
provisioner - be it StatefulSet or the Operator"
fn spec.defaults.storageManagement.withReclaimPolicy
withReclaimPolicy(reclaimPolicy)
"defines behavior of PVC
deletion.\nDelete
by default, if Retain
specified then PVC
will be kept when deleting StatefulSet\n"
obj spec.defaults.templates
"optional, configuration of the templates names which will use for generate Kubernetes resources according to one or more ClickHouse clusters described in current ClickHouseInstallation (chi) resource"
fn spec.defaults.templates.withClusterServiceTemplate
withClusterServiceTemplate(clusterServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.defaults.templates.withDataVolumeClaimTemplate
withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse data directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.defaults.templates.withHostTemplate
withHostTemplate(hostTemplate)
"optional, template name from chi.spec.templates.hostTemplates, which will apply to configure every clickhouse-server
instance during render ConfigMap resources which will mount into Pod
"
fn spec.defaults.templates.withLogVolumeClaimTemplate
withLogVolumeClaimTemplate(logVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse log directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.defaults.templates.withPodTemplate
withPodTemplate(podTemplate)
"optional, template name from chi.spec.templates.podTemplates, allows customization each Pod
resource during render and reconcile each StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.defaults.templates.withReplicaServiceTemplate
withReplicaServiceTemplate(replicaServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each replica inside each shard inside each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.defaults.templates.withServiceTemplate
withServiceTemplate(serviceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for one Service
resource which will created by clickhouse-operator
which cover all clusters in whole chi
resource"
fn spec.defaults.templates.withShardServiceTemplate
withShardServiceTemplate(shardServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each shard inside clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.defaults.templates.withVolumeClaimTemplate
withVolumeClaimTemplate(volumeClaimTemplate)
"DEPRECATED! VolumeClaimTemplate is deprecated in favor of DataVolumeClaimTemplate and LogVolumeClaimTemplate"
obj spec.reconciling
"optional, allows tuning reconciling cycle for ClickhouseInstallation from clickhouse-operator side"
fn spec.reconciling.withConfigMapPropagationTimeout
withConfigMapPropagationTimeout(configMapPropagationTimeout)
"Timeout in seconds for clickhouse-operator
to wait for modified ConfigMap
to propagate into the Pod
\nMore details: https://kubernetes.io/docs/concepts/configuration/configmap/#mounted-configmaps-are-updated-automatically\n"
fn spec.reconciling.withPolicy
withPolicy(policy)
"DEPRECATED"
obj spec.reconciling.cleanup
"optional, define behavior for cleanup Kubernetes resources during reconcile cycle"
obj spec.reconciling.cleanup.reconcileFailedObjects
"what clickhouse-operator shall do when reconciling Kubernetes resources are failed, default behavior is Retain
"
fn spec.reconciling.cleanup.reconcileFailedObjects.withConfigMap
withConfigMap(configMap)
"behavior policy for failed ConfigMap reconciling, Retain by default"
fn spec.reconciling.cleanup.reconcileFailedObjects.withPvc
withPvc(pvc)
"behavior policy for failed PVC reconciling, Retain by default"
fn spec.reconciling.cleanup.reconcileFailedObjects.withService
withService(service)
"behavior policy for failed Service reconciling, Retain by default"
fn spec.reconciling.cleanup.reconcileFailedObjects.withStatefulSet
withStatefulSet(statefulSet)
"behavior policy for failed StatefulSet reconciling, Retain by default"
obj spec.reconciling.cleanup.unknownObjects
"what clickhouse-operator shall do when found Kubernetes resources which should be managed with clickhouse-operator, but not have ownerReference
to any currently managed ClickHouseInstallation
resource, default behavior is Delete
"
fn spec.reconciling.cleanup.unknownObjects.withConfigMap
withConfigMap(configMap)
"behavior policy for unknown ConfigMap, Delete by default"
fn spec.reconciling.cleanup.unknownObjects.withPvc
withPvc(pvc)
"behavior policy for unknown PVC, Delete by default"
fn spec.reconciling.cleanup.unknownObjects.withService
withService(service)
"behavior policy for unknown Service, Delete by default"
fn spec.reconciling.cleanup.unknownObjects.withStatefulSet
withStatefulSet(statefulSet)
"behavior policy for unknown StatefulSet, Delete by default"
obj spec.templates
"allows define templates which will use for render Kubernetes resources like StatefulSet, ConfigMap, Service, PVC, by default, clickhouse-operator have own templates, but you can override it"
fn spec.templates.withHostTemplates
withHostTemplates(hostTemplates)
"hostTemplate will use during apply to generate clickhose-server
config files"
fn spec.templates.withHostTemplatesMixin
withHostTemplatesMixin(hostTemplates)
"hostTemplate will use during apply to generate clickhose-server
config files"
Note: This function appends passed data to existing values
fn spec.templates.withPodTemplates
withPodTemplates(podTemplates)
"podTemplate will use during render Pod
inside StatefulSet.spec
and allows define rendered Pod.spec
, pod scheduling distribution and pod zone\nMore information: https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#spectemplatespodtemplates\n"
fn spec.templates.withPodTemplatesMixin
withPodTemplatesMixin(podTemplates)
"podTemplate will use during render Pod
inside StatefulSet.spec
and allows define rendered Pod.spec
, pod scheduling distribution and pod zone\nMore information: https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#spectemplatespodtemplates\n"
Note: This function appends passed data to existing values
fn spec.templates.withServiceTemplates
withServiceTemplates(serviceTemplates)
"allows define template for rendering Service
which would get endpoint from Pods which scoped chi-wide, cluster-wide, shard-wide, replica-wide level\n"
fn spec.templates.withServiceTemplatesMixin
withServiceTemplatesMixin(serviceTemplates)
"allows define template for rendering Service
which would get endpoint from Pods which scoped chi-wide, cluster-wide, shard-wide, replica-wide level\n"
Note: This function appends passed data to existing values
fn spec.templates.withVolumeClaimTemplates
withVolumeClaimTemplates(volumeClaimTemplates)
"allows define template for rendering PVC
kubernetes resource, which would use inside Pod
for mount clickhouse data
, clickhouse logs
or something else"
fn spec.templates.withVolumeClaimTemplatesMixin
withVolumeClaimTemplatesMixin(volumeClaimTemplates)
"allows define template for rendering PVC
kubernetes resource, which would use inside Pod
for mount clickhouse data
, clickhouse logs
or something else"
Note: This function appends passed data to existing values
obj spec.templates.hostTemplates
"hostTemplate will use during apply to generate clickhose-server
config files"
fn spec.templates.hostTemplates.withName
withName(name)
"template name, could use to link inside top-level chi.spec.defaults.templates.hostTemplate
, cluster-level chi.spec.configuration.clusters.templates.hostTemplate
, shard-level chi.spec.configuration.clusters.layout.shards.temlates.hostTemplate
, replica-level chi.spec.configuration.clusters.layout.replicas.templates.hostTemplate
"
fn spec.templates.hostTemplates.withPortDistribution
withPortDistribution(portDistribution)
"define how will distribute numeric values of named ports in Pod.spec.containers.ports
and clickhouse-server configs"
fn spec.templates.hostTemplates.withPortDistributionMixin
withPortDistributionMixin(portDistribution)
"define how will distribute numeric values of named ports in Pod.spec.containers.ports
and clickhouse-server configs"
Note: This function appends passed data to existing values
obj spec.templates.hostTemplates.portDistribution
"define how will distribute numeric values of named ports in Pod.spec.containers.ports
and clickhouse-server configs"
fn spec.templates.hostTemplates.portDistribution.withType
withType(type)
"type of distribution, when Unspecified
(default value) then all listen ports on clickhouse-server configuration in all Pods will have the same value, when ClusterScopeIndex
then ports will increment to offset from base value depends on shard and replica index inside cluster with combination of chi.spec.templates.podTemlates.spec.HostNetwork
it allows setup ClickHouse cluster inside Kubernetes and provide access via external network bypass Kubernetes internal network"
obj spec.templates.hostTemplates.spec
fn spec.templates.hostTemplates.spec.withFiles
withFiles(files)
"optional, allows define content of any setting file inside each Pod
where this template will apply during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\n"
fn spec.templates.hostTemplates.spec.withFilesMixin
withFilesMixin(files)
"optional, allows define content of any setting file inside each Pod
where this template will apply during generate ConfigMap
which will mount in /etc/clickhouse-server/config.d/
or /etc/clickhouse-server/conf.d/
or /etc/clickhouse-server/users.d/
\n"
Note: This function appends passed data to existing values
fn spec.templates.hostTemplates.spec.withHttpPort
withHttpPort(httpPort)
"optional, setup http_port
inside clickhouse-server
settings for each Pod where current template will apply\nif specified, should have equal value with chi.spec.templates.podTemplates.spec.containers.ports[name=http]
\nMore info: https://clickhouse.tech/docs/en/interfaces/http/\n"
fn spec.templates.hostTemplates.spec.withHttpsPort
withHttpsPort(httpsPort)
fn spec.templates.hostTemplates.spec.withInsecure
withInsecure(insecure)
"optional, open insecure ports for cluster, defaults to \"yes\"\n"
fn spec.templates.hostTemplates.spec.withInterserverHTTPPort
withInterserverHTTPPort(interserverHTTPPort)
"optional, setup interserver_http_port
inside clickhouse-server
settings for each Pod where current template will apply\nif specified, should have equal value with chi.spec.templates.podTemplates.spec.containers.ports[name=interserver]
\nMore info: https://clickhouse.tech/docs/en/operations/server-configuration-parameters/settings/#interserver-http-port\n"
fn spec.templates.hostTemplates.spec.withName
withName(name)
"by default, hostname will generate, but this allows define custom name for each clickhuse-server
"
fn spec.templates.hostTemplates.spec.withSecure
withSecure(secure)
"optional, open secure ports\n"
fn spec.templates.hostTemplates.spec.withSettings
withSettings(settings)
"optional, allows configure clickhouse-server
settings inside Pod
where this template will apply during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
fn spec.templates.hostTemplates.spec.withSettingsMixin
withSettingsMixin(settings)
"optional, allows configure clickhouse-server
settings inside Pod
where this template will apply during generate ConfigMap
which will mount in /etc/clickhouse-server/conf.d/
\nMore details: https://clickhouse.tech/docs/en/operations/settings/settings/\n"
Note: This function appends passed data to existing values
fn spec.templates.hostTemplates.spec.withTcpPort
withTcpPort(tcpPort)
"optional, setup tcp_port
inside clickhouse-server
settings for each Pod where current template will apply\nif specified, should have equal value with chi.spec.templates.podTemplates.spec.containers.ports[name=tcp]
\nMore info: https://clickhouse.tech/docs/en/interfaces/tcp/\n"
fn spec.templates.hostTemplates.spec.withTlsPort
withTlsPort(tlsPort)
obj spec.templates.hostTemplates.spec.templates
"be careful, this part of CRD allows override template inside template, don't use it if you don't understand what you do"
fn spec.templates.hostTemplates.spec.templates.withClusterServiceTemplate
withClusterServiceTemplate(clusterServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.templates.hostTemplates.spec.templates.withDataVolumeClaimTemplate
withDataVolumeClaimTemplate(dataVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse data directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.templates.hostTemplates.spec.templates.withHostTemplate
withHostTemplate(hostTemplate)
"optional, template name from chi.spec.templates.hostTemplates, which will apply to configure every clickhouse-server
instance during render ConfigMap resources which will mount into Pod
"
fn spec.templates.hostTemplates.spec.templates.withLogVolumeClaimTemplate
withLogVolumeClaimTemplate(logVolumeClaimTemplate)
"optional, template name from chi.spec.templates.volumeClaimTemplates, allows customization each PVC
which will mount for clickhouse log directory in each Pod
during render and reconcile every StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.templates.hostTemplates.spec.templates.withPodTemplate
withPodTemplate(podTemplate)
"optional, template name from chi.spec.templates.podTemplates, allows customization each Pod
resource during render and reconcile each StatefulSet.spec resource described in chi.spec.configuration.clusters
"
fn spec.templates.hostTemplates.spec.templates.withReplicaServiceTemplate
withReplicaServiceTemplate(replicaServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each replica inside each shard inside each clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.templates.hostTemplates.spec.templates.withServiceTemplate
withServiceTemplate(serviceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for one Service
resource which will created by clickhouse-operator
which cover all clusters in whole chi
resource"
fn spec.templates.hostTemplates.spec.templates.withShardServiceTemplate
withShardServiceTemplate(shardServiceTemplate)
"optional, template name from chi.spec.templates.serviceTemplates, allows customization for each Service
resource which will created by clickhouse-operator
which cover each shard inside clickhouse cluster described in chi.spec.configuration.clusters
"
fn spec.templates.hostTemplates.spec.templates.withVolumeClaimTemplate
withVolumeClaimTemplate(volumeClaimTemplate)
"DEPRECATED! VolumeClaimTemplate is deprecated in favor of DataVolumeClaimTemplate and LogVolumeClaimTemplate"
obj spec.templates.podTemplates
"podTemplate will use during render Pod
inside StatefulSet.spec
and allows define rendered Pod.spec
, pod scheduling distribution and pod zone\nMore information: https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#spectemplatespodtemplates\n"
fn spec.templates.podTemplates.withDistribution
withDistribution(distribution)
"DEPRECATED, shortcut for chi.spec.templates.podTemplates.spec.affinity.podAntiAffinity
"
fn spec.templates.podTemplates.withGenerateName
withGenerateName(generateName)
"allows define format for generated Pod
name, look to https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#spectemplatesservicetemplates for details about aviailable template variables"
fn spec.templates.podTemplates.withMetadata
withMetadata(metadata)
"allows pass standard object's metadata from template to Pod\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata\n"
fn spec.templates.podTemplates.withMetadataMixin
withMetadataMixin(metadata)
"allows pass standard object's metadata from template to Pod\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata\n"
Note: This function appends passed data to existing values
fn spec.templates.podTemplates.withName
withName(name)
"template name, could use to link inside top-level chi.spec.defaults.templates.podTemplate
, cluster-level chi.spec.configuration.clusters.templates.podTemplate
, shard-level chi.spec.configuration.clusters.layout.shards.temlates.podTemplate
, replica-level chi.spec.configuration.clusters.layout.replicas.templates.podTemplate
"
fn spec.templates.podTemplates.withPodDistribution
withPodDistribution(podDistribution)
"define ClickHouse Pod distribution policy between Kubernetes Nodes inside Shard, Replica, Namespace, CHI, another ClickHouse cluster"
fn spec.templates.podTemplates.withPodDistributionMixin
withPodDistributionMixin(podDistribution)
"define ClickHouse Pod distribution policy between Kubernetes Nodes inside Shard, Replica, Namespace, CHI, another ClickHouse cluster"
Note: This function appends passed data to existing values
fn spec.templates.podTemplates.withSpec
withSpec(spec)
"allows define whole Pod.spec inside StaefulSet.spec, look to https://kubernetes.io/docs/concepts/workloads/pods/#pod-templates for details"
fn spec.templates.podTemplates.withSpecMixin
withSpecMixin(spec)
"allows define whole Pod.spec inside StaefulSet.spec, look to https://kubernetes.io/docs/concepts/workloads/pods/#pod-templates for details"
Note: This function appends passed data to existing values
obj spec.templates.podTemplates.podDistribution
"define ClickHouse Pod distribution policy between Kubernetes Nodes inside Shard, Replica, Namespace, CHI, another ClickHouse cluster"
fn spec.templates.podTemplates.podDistribution.withNumber
withNumber(number)
"define, how much ClickHouse Pods could be inside selected scope with selected distribution type"
fn spec.templates.podTemplates.podDistribution.withScope
withScope(scope)
"scope for apply each podDistribution"
fn spec.templates.podTemplates.podDistribution.withTopologyKey
withTopologyKey(topologyKey)
"use for inter-pod affinity look to pod.spec.affinity.podAntiAffinity.preferredDuringSchedulingIgnoredDuringExecution.podAffinityTerm.topologyKey
, More info: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity"
fn spec.templates.podTemplates.podDistribution.withType
withType(type)
"you can define multiple affinity policy types"
obj spec.templates.podTemplates.zone
"allows define custom zone name and will separate ClickHouse Pods
between nodes, shortcut for chi.spec.templates.podTemplates.spec.affinity.podAntiAffinity
"
fn spec.templates.podTemplates.zone.withKey
withKey(key)
"optional, if defined, allows select kubernetes nodes by label with name
equal key
"
fn spec.templates.podTemplates.zone.withValues
withValues(values)
"optional, if defined, allows select kubernetes nodes by label with value
in values
"
fn spec.templates.podTemplates.zone.withValuesMixin
withValuesMixin(values)
"optional, if defined, allows select kubernetes nodes by label with value
in values
"
Note: This function appends passed data to existing values
obj spec.templates.serviceTemplates
"allows define template for rendering Service
which would get endpoint from Pods which scoped chi-wide, cluster-wide, shard-wide, replica-wide level\n"
fn spec.templates.serviceTemplates.withGenerateName
withGenerateName(generateName)
"allows define format for generated Service
name, look to https://github.com/Altinity/clickhouse-operator/blob/master/docs/custom_resource_explained.md#spectemplatesservicetemplates for details about aviailable template variables"
fn spec.templates.serviceTemplates.withMetadata
withMetadata(metadata)
"allows pass standard object's metadata from template to Service\nCould be use for define specificly for Cloud Provider metadata which impact to behavior of service\nMore info: https://kubernetes.io/docs/concepts/services-networking/service/\n"
fn spec.templates.serviceTemplates.withMetadataMixin
withMetadataMixin(metadata)
"allows pass standard object's metadata from template to Service\nCould be use for define specificly for Cloud Provider metadata which impact to behavior of service\nMore info: https://kubernetes.io/docs/concepts/services-networking/service/\n"
Note: This function appends passed data to existing values
fn spec.templates.serviceTemplates.withName
withName(name)
"template name, could use to link inside\nchi-level chi.spec.defaults.templates.serviceTemplate
\ncluster-level chi.spec.configuration.clusters.templates.clusterServiceTemplate
\nshard-level chi.spec.configuration.clusters.layout.shards.temlates.shardServiceTemplate
\nreplica-level chi.spec.configuration.clusters.layout.replicas.templates.replicaServiceTemplate
or chi.spec.configuration.clusters.layout.shards.replicas.replicaServiceTemplate
\n"
fn spec.templates.serviceTemplates.withSpec
withSpec(spec)
"describe behavior of generated Service\nMore info: https://kubernetes.io/docs/concepts/services-networking/service/\n"
fn spec.templates.serviceTemplates.withSpecMixin
withSpecMixin(spec)
"describe behavior of generated Service\nMore info: https://kubernetes.io/docs/concepts/services-networking/service/\n"
Note: This function appends passed data to existing values
obj spec.templates.volumeClaimTemplates
"allows define template for rendering PVC
kubernetes resource, which would use inside Pod
for mount clickhouse data
, clickhouse logs
or something else"
fn spec.templates.volumeClaimTemplates.withMetadata
withMetadata(metadata)
"allows to pass standard object's metadata from template to PVC\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata\n"
fn spec.templates.volumeClaimTemplates.withMetadataMixin
withMetadataMixin(metadata)
"allows to pass standard object's metadata from template to PVC\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata\n"
Note: This function appends passed data to existing values
fn spec.templates.volumeClaimTemplates.withName
withName(name)
"template name, could use to link inside\ntop-level chi.spec.defaults.templates.dataVolumeClaimTemplate
or chi.spec.defaults.templates.logVolumeClaimTemplate
,\ncluster-level chi.spec.configuration.clusters.templates.dataVolumeClaimTemplate
or chi.spec.configuration.clusters.templates.logVolumeClaimTemplate
,\nshard-level chi.spec.configuration.clusters.layout.shards.temlates.dataVolumeClaimTemplate
or chi.spec.configuration.clusters.layout.shards.temlates.logVolumeClaimTemplate
\nreplica-level chi.spec.configuration.clusters.layout.replicas.templates.dataVolumeClaimTemplate
or chi.spec.configuration.clusters.layout.replicas.templates.logVolumeClaimTemplate
\n"
fn spec.templates.volumeClaimTemplates.withProvisioner
withProvisioner(provisioner)
"defines PVC
provisioner - be it StatefulSet or the Operator"
fn spec.templates.volumeClaimTemplates.withReclaimPolicy
withReclaimPolicy(reclaimPolicy)
"defines behavior of PVC
deletion.\nDelete
by default, if Retain
specified then PVC
will be kept when deleting StatefulSet\n"
fn spec.templates.volumeClaimTemplates.withSpec
withSpec(spec)
"allows define all aspects of PVC
resource\nMore info: https://kubernetes.io/docs/concepts/storage/persistent-volumes/#persistentvolumeclaims\n"
fn spec.templates.volumeClaimTemplates.withSpecMixin
withSpecMixin(spec)
"allows define all aspects of PVC
resource\nMore info: https://kubernetes.io/docs/concepts/storage/persistent-volumes/#persistentvolumeclaims\n"
Note: This function appends passed data to existing values
obj spec.templating
"Optional, defines policy for applying current ClickHouseInstallationTemplate to ClickHouseInstallation(s)"
fn spec.templating.withChiSelector
withChiSelector(chiSelector)
"Optional, defines selector for ClickHouseInstallation(s) to be templated with ClickhouseInstallationTemplate"
fn spec.templating.withChiSelectorMixin
withChiSelectorMixin(chiSelector)
"Optional, defines selector for ClickHouseInstallation(s) to be templated with ClickhouseInstallationTemplate"
Note: This function appends passed data to existing values
fn spec.templating.withPolicy
withPolicy(policy)
"When defined as auto
inside ClickhouseInstallationTemplate, this ClickhouseInstallationTemplate\nwill be auto-added into ClickHouseInstallation, selectable by chiSelector
.\nDefault value is manual
, meaning ClickHouseInstallation should request this ClickhouseInstallationTemplate explicitly.\n"
obj spec.useTemplates
"list of ClickHouseInstallationTemplate
(chit) resource names which will merge with current Chi
manifest during render Kubernetes resources to create related ClickHouse clusters"
fn spec.useTemplates.withName
withName(name)
"name of ClickHouseInstallationTemplate
(chit) resource"
fn spec.useTemplates.withNamespace
withNamespace(namespace)
"Kubernetes namespace where need search chit
resource, depending on watchNamespaces
settings in clichouse-operator
"
fn spec.useTemplates.withUseType
withUseType(useType)
"optional, current strategy is only merge, and current chi
settings have more priority than merged template chit
"