Skip to content

johnnymetz/fluent-bit-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fluent-bit-demo

Fluent Bit Demo

Based on GitHub - fluent/fluent-bit-kubernetes-logging: Fluent Bit Kubernetes Daemonset

Getting Started

Create app with logs in default namespace:

kubectl apply -f ./counter.yaml
kubectl logs pod/counter

Next, replace the host path in fluent-bit-daemonset.yaml with the absolute path to the logs/ in this repo, e.g. /path/to/logs

Create fluent bit daemonset:

kubectl create ns logging

kubectl apply -f https://raw.githubusercontent.com/fluent/fluent-bit-kubernetes-logging/master/fluent-bit-service-account.yaml
kubectl apply -f https://raw.githubusercontent.com/fluent/fluent-bit-kubernetes-logging/master/fluent-bit-role-1.22.yaml
kubectl apply -f https://raw.githubusercontent.com/fluent/fluent-bit-kubernetes-logging/master/fluent-bit-role-binding-1.22.yaml

kubectl apply -f fluent-bit-configmap.yaml
kubectl apply -f fluent-bit-daemonset.yaml

Notice the logs/ folder is populated with several files, including one for the counter pod.

Development

kubectl delete -f fluent-bit-daemonset.yaml
kubectl apply -f fluent-bit-configmap.yaml
kubectl apply -f fluent-bit-daemonset.yaml

Cleanup

kubectl delete -n default pod/counter
kubectl delete ns logging

Resources

Releases

No releases published

Packages

No packages published