Derived from the Norse God Heimdall who keeps watch, this is an implementation of event controller that looks out for any event that occurs on the k8 cluster. This is created in an effort to understand and implement the following:
- Kubernetes client-go package
- Controller pattern in Kubernetes by use of shared informers and watch
Heimdall watches over the cluster using the kubernetes controller pattern and updates the user in case of any new events on the kubernetes cluster
- Access to a Kubernetes cluster
- Currently the code assumes that the kubeconfig file will be found in
~/.kube/config
- The user should have full access pan cluster for
Event
resource
Upon execution the kubernetes events are printed to stdout and the corresponding parsed event fields are logged subsequently
$ go run cmd/main.go
NOTE
optionally user can also provide -kubeconfig
to override default kubeconfig settings