Jerry Emilo

Local K8S Development

✏️ Summary

I am constantly researching technology for my work and personal projects. Most recently I’ve been diving into the state of local K8S development. There are a lot of options out there now that support local development, remote development, and a mixture of both. This is super awesome compared to the state of things a few years ago. During my research I decided to go with one of the more popular mature projects Tilt. This project recently had its team join Docker. Which I’m hoping will help the project grow and mature with more resources. It is a simple easy to use well documented solution that works well and definitely covers the use case for the video associated with this blog post.

I have also been diving into many of the projects being incubated by the Cloud Native Computing Foundation. If one were to glance at the landscape of all the projects being incubated by CNCF they could start to piece together that many of the key products and services offered by cloud providers are available here as open source projects. CNCF is incubating projects that can run on k8s which can augment a majority of the crucial services offered by cloud providers. Essentially, CNCF is incubating an open source cloud. Once I pieced this together I decided to dive into CNCF incubated projects to learn what I believe is the future of the cloud ecosystem.

The reason why a tech stack such as this is important is that it can truly be run anywhere. At your home lab, at on premise datacenter, at cloud providers, and any hosting provider that lets you spin up servers. One of the key reason that I think k8s is the ideal platform for most projects is that you can set fixed costs. What I mean by that is that unlike cloud hosted Serverless platforms that charge by usage, you can spin up a basic high availability k8s cluster for fixed monthly cost. Then if architected well using an event driven approach resources to be flexed appropriately to keep things running smoothly at reasonable costs.

If you just need a basic web application with a simple API there are many providers out there that can run this for near free every month. However, if you are trying to run a more advanced application that requires always running services, background processes, has lots of moving pieces, and is constantly crunching data hosted serverless platforms can get pricey. As a cost conscious pragmatic engineer, I enjoy the control and flexibility that K8S offers without having to worry about a spike of traffic or a malicious actor DDOSing my services. That type of action would skyrocket the costs of a hosted serverless platform and more than likely cause the services to go down due to hitting any acceptable use service limits imposed on many platforms.

💪 local-k8s-demo

As part of this effort of learning I have created a video demonstration of how I went about creating a basic project to show one of the many ways to develop a project locally using K8S.

🎁 What is included

  • Monorepo
  • Local K8S development
  • Web Application / API
  • Worker Service
  • Database
  • Queue
  • Event based auto-scaling

💻 Tech Stack

✅ Repository

local-k8s-demo

📼 Video

I tried to keep the video to around an hour, so it is a quick overview and some areas are sped up to make sure it did not get to lengthy. I hope you enjoy it and find it useful. Local K8s Dev

📨 Questions, Issues, and Suggestions?

Please submit any questions, issues, or suggestions directly to the Github repository for this project k8s-local-dev