My k3s OpenFaaS Raspberry Pi cluster
A few months ago I build a Raspberry Pi cluster running K3S. I build it because I wanted to have a nice environment the learn more about Kubernetes and OpenFaas. It always feels nice to have something you can actually touch in this all software world I normally live in. After tweeting and giving a session about my OpenFaas Raspberry Pi cluster people started asking what parts the cluster consists of and what software I use to run it. In this blog I will list the used hardware, explain some choices and list a few blogs that were used.
Hardware
Here’s a list of the hardware you see in the image above.
- 3x Raspberry Pi 3B+
- The heart of the cluster. You now might want to buy the 4
- 3x 32Gb Sandisk SD-card
- Buy big onces and get high performance cards
- Netgear GS305-100PS switch
- USB to dc cable
- All the other parts in the cluster are powered using a micro USB cable except the Netgear switch. Using this cable I can now power all devices using the Ravpower USB power supply
- MikroTik Hap Lite router
- I wanted my cluster to be as portable as it could be and not to interfere with my home network. This router is small, fits in the cluster case and is powered by USB
- Ravpower power supply
- 3x Micro-usb cable
- Raspberry Pi 3
- I wanted to be able to place my cluster anywhere I want but it needs an internet connection and there no cable everywhere in my house. So, I picked up another Pi I had lying around. This Pi is now used as a bridge between the cluster and the home WiFi.
- Cluster Case
Software
These are the blogs I used to build my cluster:
- Will it cluster? k3s on your Raspberry Pi by Alex Ellis
- Just follow this blog and you’ll be okay!
- How to Build a Kubernetes Cluster with ARM Raspberry Pi then run .NET Core on OpenFaas by Scott Hanselman
- Great read with great explanation on hardware choices and .Net Core on ARM
- Use the extra Pi as a WiFi bridge
- I also use the extra Pi as a build server for the Net Core functions https://blog.docker.com/2019/03/happy-pi-day-docker-raspberry-pi/