How to set up the Elastic stack on Kubernetes
Clone or download
Latest commit 28e517d Nov 17, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs Upgrades (#37) Nov 21, 2017
helm/g8s-efk-chart Add original images Nov 13, 2018
manifests Update fluentd Nov 8, 2018
test Fluent bit (#30) Jun 6, 2017
README.md Upgrades (#37) Nov 21, 2017
manifests-all.yaml Comment ingress Nov 8, 2018

README.md

Logging with Elastic in Kubernetes

See docs for full recipe content.

This setup is similar to the Full Stack Example, but adopted to be run on a Kubernetes cluster.

There is no access control for the Kibana web interface. If you want to run this in public you need to secure your setup. The provided manifests here are for demonstration purposes only.

Local Setup

Start a local Kubernetes using minikube

If some webpages don't show up immediately wait a bit and reload. Also the Kubernetes Dashboard needs reloading to update its view.

minikube start --memory 4096

minikube dashboard
# maybe wait a bit and retry
kubectl get --all-namespaces services,pods

Logging with Elasticsearch and fluentd

kubectl apply \
  --filename https://raw.githubusercontent.com/giantswarm/kubernetes-elastic-stack/master/manifests-all.yaml

minikube service kibana

For the index pattern in Kibana choose fluentd-*, then switch to the "Discover" view. Every log line by containers running within the Kubernetes cluster is enhanced by meta data like namespace_name, labels and so on. This way it is easy to group and filter down on specific parts.

Turn down all logging components

kubectl delete \
  --filename https://raw.githubusercontent.com/giantswarm/kubernetes-elastic-stack/master/manifests-all.yaml

FIXME alternatively --selector stack=logging

To delete the whole local Kubernetes cluster use this:

minikube delete