How to Integrate Kibana with Elasticsearch in a Local Kubernetes Setup Using Kind and Helm?

Camunda recommends using a local Kubernetes cluster based on Kind/Helm for development, which is better than Docker Compose setup because ‘closer to production’.

I used Docker Compose for a while but switched now to the setup with Kind (Kubernetes in Docker) and Helm. The only feature I miss however is the easy integration of Kibana to view Elasticsearch data, which was straightforward with a Docker Compose profile.

How can I achieve the same with Kind/Helm configuration?

Here an example how to solve it using additional Kibana deployment and service in Kubernetes assuming Elasticsearch can be accessed using service (default)
camunda-platform-elasticsearch:9200:

apiVersion: apps/v1
kind: Deployment
metadata:
  name: kibana
  namespace: default
spec:
  replicas: 1
  selector:
    matchLabels:
      app: kibana
  template:
    metadata:
      labels:
        app: kibana
    spec:
      containers:
      - name: kibana
        image: kibana:8.15.2
        env:
        - name: ELASTICSEARCH_HOSTS
          value: "http://camunda-platform-elasticsearch:9200"
        ports:
        - containerPort: 5601
          name: kibana
---
apiVersion: v1
kind: Service
metadata:
  name: kibana
  namespace: default
spec:
  selector:
    app: kibana
  ports:
    - protocol: TCP
      port: 5601
      targetPort: 5601
  type: ClusterIP

And then just create a tunnel to be able to access Kibana:

kubectl port-forward svc/kibana 5601:5601
1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.