On a recent Meetup in Zürich I had a first encounter with JenkinsX, the emerging Kubernetes based version of Jenkins CI. Pretty much impressed on what is currently being built, I quickly realised how powerful and complex this beast is.

JenkinsX is now orchestrating a full ecosystem including git source repos, helm chart and artifact repos, staging and production environments and even PR based preview environments. Pretty cool.

I found it quite hard to follow whats going on in detail. You actually can follow the state of the pipelines using the new cli client: jx get activities .

However, I decided create my own small dashboard using my event-monitoring tool called MetaControl.

MetaControl aggregates meta events from various sources and provides aggregated views on a status/severity level. It’s currently in beta and freely accessible. Check it out here.

The result is a mashup of the whole process in combination with live events happening giving me a bird-level view on the whole construct. It consists of graphical elements built as SVG (painted with Powerpoint and Inkscape) and a range of widgets embedded which display the current state.

The widgets are displaying a traffic light-like status indicators in combination with a severity level. Depending on the layout they also show historical states and the identity/category of the event.

Clicking on the widgets will provide a 2-level list/detail view for drilling down into single events.

You will also find full meta information attached to the event, useful for deeper investigations.

Ingredients

In order to bring events from the various parts of the pipeline onto the dashboard a couple of integrations with MetaControl are needed:

Kubernetes API events from various namespaces

As said JenkinsX uses quite some k8s resources for providing build containers, preview/staging/production environments and the utility services around. Any events happening on API level are also interesting when operating the pipelines.

I have written a small probe attaching to the k8s API which is forwarding the events to MetaControl using a variation of https://github.com/verticle-io/oculus.

jx pipeline activities

Basically jx pipeline events are custom resource definitions (CRDs) in Kubernetes. You can follow them the same way as API events. They contain information on CI stages, their processing steps and detailed information on builds and artifacts.

Github events

JX also hooks into Github repos. It even manages promotions and uses gitops to handle the deployment state of the k8s environments so it’s pretty active in the various repos. In order to follow those actions I applied webhooks to each repo that post all actions to a specific webhook processor on MetaControl. The payloads are processed and transformed into MetaControl compatible events.

Other sources

I skipped other sources that would be worth monitoring as well, like the repositories for helm charts and the build artifacts. They might be candidates for an upcoming version though.

You could also send events from your deployed applications to the dashboard (e.g. health states or similar) or send machine stats, just to mention a few potential extensions.

Watching events in MetaControl

Once all sources are attached they get visible in the MetaControl UI. Kicking off the JX demo application and starting the CI flow from Github will produce something like this: