elasticsearch

by HelmForge

Helm chartv2.1.1App 9.5.5Apache-2.0Verified publisher

Production-ready Elasticsearch cluster with intelligent presets, automated backups, ILM policies, and multi-role architecture

About this chart

Elasticsearch Helm Chart

Production-ready Elasticsearch cluster chart using the official Elastic image. Deploys multi-role clusters from a single clusterProfile setting, with automated S3 backups, ILM lifecycle policies, cert-manager TLS, data tiers, and Grafana dashboards included out of the box.

Install

HTTPS repository

helm repo add helmforge https://repo.helmforge.dev
helm repo update
helm install es helmforge/elasticsearch

OCI registry

helm install es oci://ghcr.io/helmforgedev/helm/elasticsearch

Quick Start

# Dev profile — single node, no TLS, fast startup
helm install es helmforge/elasticsearch

# Production HA — 3 master + 3 data + 2 coordinating, TLS, PDBs
helm install es helmforge/elasticsearch \
  --set clusterProfile=production-ha \
  --set security.enabled=true \
  --set security.tls.certManager.enabled=true

Cluster Profiles

ProfileMastersDataCoordinatingTLSPDB
dev1 (all roles)——NoNo
staging12—NoData only
production-ha332AutoAll roles

Read before choosing a profile:

  • Dev profile — single node, local development
  • Staging profile — small cluster, representative environments
  • Production HA profile — full HA cluster, data tiers, monitoring
  • Backup and restore — S3 snapshots and point-in-time recovery
  • Security and TLS — cert-manager, password management, mTLS

Key Features

  • Profile-driven — dev, staging, production-ha presets with tuned defaults
  • Multi-role StatefulSets — dedicated pods per role: master, data, coordinating
  • Auto heap sizing — 50% rule applied from container memory limit (max 31 GB), no manual JVM tuning
  • Split-brain prevention — validates an odd master count for multi-node clusters
  • Data tiers — optional hot/warm nodes with separate storage classes and ILM attribute routing
  • S3 snapshots — scheduled CronJob with configurable retention, repository auto-registration
  • ILM policies — pre-built templates for logs, metrics, and traces (hot→warm→cold→delete)
  • cert-manager TLS — issues multi-SAN certificates for internode and client traffic
  • Monitoring — Prometheus exporter sidecar, ServiceMonitor, 6 alert rules, 3 Grafana dashboards
  • Optional Kibana — auto-connected with shared TLS and Ingress support
  • PodDisruptionBudgets — for master, data, coordinating, hot, and warm roles
  • Authoritative configuration — one generated elasticsearch.yml is mounted into every node role
  • Independent ports — process listeners, Services, Kibana, and metrics ports are configurable independently

Configuration

Dev (single node)

# All defaults — clusterProfile: dev is the default
clusterName: dev-cluster

Staging (small cluster)

clusterProfile: staging

master:
  persistence:
    size: 20Gi

data:
  persistence:
    size: 100Gi

Production HA

clusterProfile: production-ha

clusterName: production-es

master:
  persistence:
    size: 20Gi

data:
  persistence:
    size: 500Gi

security:
  enabled: true
  tls:
    certManager:
      enabled: true
      clusterIssuer: true
      issuerName: letsencrypt-prod

backup:
  enabled: true
  schedule: "0 2 * * *"
  s3:
    bucket: my-es-backups
    region: us-east-1
    existingSecret: es-s3-creds

ilm:
  logs:
    enabled: true
  metrics:
    enabled: true

monitoring:
  enabled: true
  serviceMonitor:
    enabled: true
  prometheusRule:
    enabled: true
  grafana:
    dashboards: true

Elasticsearch configuration and ports

The chart renders one elasticsearch.yml ConfigMap and mounts it at /usr/share/elasticsearch/config/elasticsearch.yml in every Elasticsearch container. Use extraConfig for additional settings. Chart-managed cluster, discovery, security, and listener settings are reserved so all roles remain consistent.

containerPorts:
  http: 19200
  transport: 19300

service:
  port: 9200

extraConfig:
  cluster.routing.allocation.disk.watermark.low: "82%"

service.port is the client-facing Kubernetes Service port. It targets the named HTTP container port. Inter-node transport is exposed only by the role headless Services.

The main Service selects coordinating nodes when present, then regular data nodes, then an enabled data tier, and finally master nodes for the dev profile. It never selects Kibana pods.

Elasticsearch requires vm.max_map_count=262144 on every Kubernetes node. Configure it at the node level. sysctlInit.enabled is an opt-in fallback that requires permission to run a privileged init container.

With Data Tiers

clusterProfile: production-ha

dataTiers:
  hot:
    enabled: true
    replicas: 3
    storage: 200Gi
    storageClass: fast-ssd
  warm:
    enabled: true
    replicas: 2
    storage: 1Ti
    storageClass: standard

Parameters

Global

ParameterDescriptionDefault
clusterProfileCluster preset: dev, staging, production-hadev
namespaceOverrideNamespace for chart-managed namespaced resources""
clusterNameElasticsearch cluster namehelmforge-cluster
image.repositoryElasticsearch imagedocker.io/library/elasticsearch
image.tagImage tag9.5.5
containerPorts.httpElasticsearch HTTP process listener9200
containerPorts.transportElasticsearch transport process listener9300
nameOverrideOverride chart name""
fullnameOverrideOverride full release name""

Master Nodes

ParameterDescriptionDefault
master.replicaCountOverride profile-driven replica countprofile-driven
master.heapSizeJVM heap (auto-calculated if empty)""
master.resourcesCPU/memory requests and limitsprofile-driven
master.persistence.sizePVC size per master podprofile-driven
master.persistence.storageClassStorage class""
master.podAnnotationsPod annotations{}
master.nodeSelectorNode selector{}
master.tolerationsTolerations[]

Data Nodes

ParameterDescriptionDefault
data.replicaCountOverride profile-driven replica countprofile-driven
data.heapSizeJVM heap (auto-calculated if empty)""
data.resourcesCPU/memory requests and limitsprofile-driven
data.persistence.sizePVC size per data podprofile-driven
data.persistence.storageClassStorage class""

Coordinating Nodes

ParameterDescriptionDefault
coordinating.replicaCountOverride profile-driven replica countprofile-driven
coordinating.heapSizeJVM heap""
coordinating.resourcesCPU/memory requests and limitsprofile-driven

Security

ParameterDescriptionDefault
security.enabledEnable X-Pack security (TLS + auth)false (true in prod-ha)
security.tls.certManager.enabledIssue TLS via cert-managerfalse
security.tls.certManager.clusterIssuerUse ClusterIssuer instead of Issuerfalse
security.tls.certManager.issuerNameIssuer/ClusterIssuer nameselfsigned-issuer
security.existingTlsSecretPre-existing TLS secret (keys: ca.crt, tls.crt, tls.key)""
security.existingCredentialsSecretPre-existing credentials secret""
security.generatePasswordsAuto-generate passwordstrue

Backup

ParameterDescriptionDefault
backup.enabledEnable scheduled S3 snapshotsfalse
backup.scheduleCron schedule"0 2 * * *"
backup.retention.daysDelete snapshots older than N days30
backup.s3.bucketS3 bucket name""
backup.s3.regionAWS regionus-east-1
backup.s3.endpointCustom endpoint (MinIO, GCS, etc.)""
backup.s3.existingSecretSecret with access-key / secret-key""
backup.s3.existingSecretAccessKeyKeyAccess-key field in the existing or generated Secretaccess-key
backup.s3.existingSecretSecretKeyKeySecret-key field in the existing or generated Secretsecret-key
backup.s3.credentialsFromPodIdentityUse the Elasticsearch pod workload identity; bucket must existfalse
backup.serviceAccount.createCreate the dedicated snapshot CronJob ServiceAccounttrue
backup.serviceAccount.nameSnapshot CronJob ServiceAccount name override""
master.persistence.retentionPolicy.whenDeletedMaster PVC retention after StatefulSet deletion""
master.persistence.retentionPolicy.whenScaledMaster PVC retention after scale-down""
data.persistence.retentionPolicy.whenDeletedData PVC retention after StatefulSet deletion""
data.persistence.retentionPolicy.whenScaledData PVC retention after scale-down""

ILM Policies

ParameterDescriptionDefault
ilm.logs.enabledCreate helmforge-logs ILM policyfalse
ilm.logs.hotDaysDays in hot phase7
ilm.logs.warmDaysDays in warm phase30
ilm.logs.coldDaysDays in cold phase90
ilm.logs.deleteDaysDays until deletion180
ilm.metrics.enabledCreate helmforge-metrics ILM policyfalse
ilm.traces.enabledCreate helmforge-traces ILM policyfalse

Data Tiers

ParameterDescriptionDefault
dataTiers.hot.enabledEnable dedicated hot tier nodesfalse
dataTiers.hot.replicasHot tier replica count2
dataTiers.hot.storageHot tier PVC size200Gi
dataTiers.hot.storageClassHot tier storage class (e.g. fast-ssd)""
dataTiers.warm.enabledEnable dedicated warm tier nodesfalse
dataTiers.warm.replicasWarm tier replica count2
dataTiers.warm.storageWarm tier PVC size1Ti
dataTiers.warm.storageClassWarm tier storage class (e.g. standard)""

Monitoring

ParameterDescriptionDefault
monitoring.enabledDeploy Prometheus exporter sidecarfalse
monitoring.containerPortExporter process listener9114
monitoring.service.portMetrics Service port9114
monitoring.image.repositoryExporter imageprometheuscommunity/elasticsearch-exporter
monitoring.image.tagExporter tagv1.8.0
monitoring.serviceMonitor.enabledCreate ServiceMonitorfalse
monitoring.serviceMonitor.intervalScrape interval30s
monitoring.prometheusRule.enabledCreate PrometheusRule (6 alerts)false
monitoring.grafana.dashboardsCreate Grafana dashboard ConfigMapsfalse

Kibana

ParameterDescriptionDefault
kibana.enabledDeploy Kibana alongside Elasticsearchfalse
kibana.image.tagKibana version (must match ES version)9.5.5
kibana.replicaCountKibana replica count1
kibana.containerPortKibana process listener5601
kibana.service.portKibana Service port5601
kibana.ingress.enabledExpose Kibana via Ingressfalse
kibana.ingress.hostsIngress hostnames[kibana.example.com]

Service

ParameterDescriptionDefault
service.typeService type for HTTP accessClusterIP
service.portClient-facing Elasticsearch HTTP Service port9200
service.ipFamilyPolicyService dual-stack policy for HTTP and headless Servicesnull
service.ipFamiliesService IP families for HTTP and headless Services[]

Service Account

ParameterDescriptionDefault
serviceAccount.createCreate a dedicated ServiceAccountfalse
serviceAccount.nameServiceAccount name override""
serviceAccount.automountServiceAccountTokenMount Kubernetes API token into workload podsfalse

Gateway API and External Secrets

gatewayAPI:
  enabled: true
  httpRoutes:
    - name: public
      hostnames: [elasticsearch.example.com]
      parentRefs:
        - name: shared-gateway
          namespace: gateway-system

externalSecrets:
  enabled: true
  refreshInterval: 1h
  items:
    - name: credentials
      spec:
        secretStoreRef:
          name: production-secrets
          kind: ClusterSecretStore
        target:
          creationPolicy: Owner
        data:
          - secretKey: elastic-password
            remoteRef:
              key: elasticsearch
              property: elastic-password
          - secretKey: kibana-system-password
            remoteRef:
              key: elasticsearch
              property: kibana-system-password

The Gateway controller and External Secrets Operator CRDs must already exist. The chart does not install either controller.

Security Scan

Security Scan: elasticsearch

FrameworkScore
MITRE + NSA + SOC286.36364%

Security posture acceptable.

Other

ParameterDescriptionDefault
sysctlInit.enabledSet vm.max_map_count=262144 through a privileged init containerfalse
terminationGracePeriodSecondsGrace period for pod shutdown120
extraEnvExtra environment variables[]
extraVolumesExtra volumes[]
extraVolumeMountsExtra volume mounts[]
extraConfigAdditional mounted elasticsearch.yml settings{}
nodeSelectorGlobal node selector{}
tolerationsGlobal tolerations[]
priorityClassNamePriority class""

Upgrade Notes

Version 2 breaking changes

Version 2 fixes the previously generated-but-unmou

Deploy elasticsearch with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has elasticsearch on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartelasticsearch is pinned at v2.1.1 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply