Saturday, August 22, 2020

Welcome to 2020! Err...I mean, welcome to August 2020!

I love home projects where the main purpose is to learn something new. The only projects I love more are the next learning projects.

Here are some areas I want to learn more about:
  • Kubernetes
  • Tracking useful metrics
  • For the near future:
    • Serverless for Kubernetes
    • Load testing at a small scale
    • Data pipelines

Some of the items are very easy to explore at work but not all of them, so I plan to focus on projects that are not work specific.

Kubernetes


You might ask, "Who isn't using Kubernetes?"

Well, I wasn't until recently!

It's been really fun. There are so many open-source projects that I want to use that will easily run on Kubernetes that it's almost hard to force myself to start at the beginning and learn how to set up and manage a cluster. Or even a tiny cluster - but that's what I'll do first!

I had wanted to make a Raspberry Pi cluster for a while and this provided the excuse. I bought some Raspberry Pis, a nice case, an unmanaged switch that had 8 PoE ports, PoE hats for the Raspberry Pis, SD cards, and network cables. I put the Pis in the case, installed k3s (Lightweight Kubernetes), and now I just need some projects to help provide areas to start digging!

I'll share the steps I followed, parts I used for putting the cluster together, and anything I might do differently if I were to start over in the near future.

Tracking Useful Metrics


One of my first plans for the cluster will be to add metric tracking. I'm not sure what metric tracking options there are, so I searched to find out what other people are using. I found a number of references to this cluster-monitoring repo, and it looks like the setup for k3s is very simple. I forked and cloned that repo, followed the quick start info for k3s (updated some configs), and Prometheus, AlertManager, and Grafana were soon available and showing some useful metrics!

I'll create a post about what I learn with monitoring in the near future. 

Recommendations:


Following the Quickstart for K3s from the carlosedp/cluster-monitoring repo was very straightforward, and it would be my suggested monitoring choice to anyone setting up a Raspberry Pi based Kubernetes cluster. I might change my mind, but for now it seems like an easy and quick way to go.

For now I suggest forking the repo, and then push any changes you make to vars.jsonnet to your cluster-monitoring repo. That way you can add/remove monitoring for your cluster quickly using a script that clones your repo first.

Near Future Projects


There are a number of things that I want to explore at home:
  • Serverless options for Kubernetes (for example, OpenFaaS, KNative, and Kubeless)
  • Load testing at a small scale (for example, run load tests against a single service as part of a CI pipeline, or run a set of load tests against a smaller version of your production environment)
  • Explore a variety of data pipelines




No comments:

Post a Comment