I Run Kubernetes Btw
Its been quite a while since I’ve posted here so I think it’s about time I gave a homelab update! So we’re gonna talk about what my homelab used to be, the pain points I had with that setup and where I am now and why!
What my homelab used to be
My homelab has gone through a bunch of changes over the years I’ve had it. I started out with one lonely Dell R610 that ran Proxmox with vms running containers. That lasted actually quite a while with me adding a couple Dell R620’s to increase my compute capacity. I was always short on storage so each of the blade servers only had a few HDDs in them.
…My Dev Environment Anywhere
So I recently bought a steam deck. If you don’t know what a steam deck is go check it out at steamdeck.com! Ultimately its a device built for playing PC games but portable. Its got an AMD x86 APU with 16GB of ram, which paired with its 1280x800 display lets it run a ton of games at very decent graphics settings. Its a fantastic gaming device and I’ve had a ton of fun recently working through my steam library. But really gaming is not the thing that gets me the most excited about the steam deck. Under the hood the steam deck runs Arch Linux and runs on a read-only root file system. This forces a new paradigm for installing and running applications. The best solutions, in my opinion, rely on running apps in containers, like flatpak. But I spend a large amount of my time in the command line and installing command line tools via flatpak is clunky. But wouldn’t it be cool if I could run my entire development environment inside a container…
…Transfering Large Files at Full Speed
So recently i was moving some… linux isos… between my desktop and server and was getting only 65MB/s… I have a wired 1Gb/s ethernet connection between the boxes so i felt like it should be faster… last night i got curious and decided to figure out why i wasnt able to saturate my network and where my bottle neck was… tldr; transfering files via scp/rsync has a ton of overhead…
…Homelab Pt 1 - Goal
Homelab is a series about getting started in building a “homelab”. We will be going through everything from “why” to “how” and all things in between.
You need a goal
Every project is better when theres a clear goal in mind. Any questions you have along the way of “which tool should I use?” or “how much money or time should I invest in this?” can be much more easily answered when you have a goal in mind. Also having a goal can add more drive to your project, a goal can help you get up off your couch, grab that laptop, sit right back down on that couch and push that goal further along!
…My First Awx
I’m a little bit of an ansible fan boy. But for good reason! Ansible is a fantastic way to provision, deploy and update machines and applications. It can do just about anything you can think of and it make one thing very easy, “gitops”.
My background and career is as a software developer and CI/CD practices and their huge benefits are engrained in me and so the idea that I could describe my home infrastructure as code and then “auto deploy” that code after its pushed up just rings so true with me. Ever since I started using ansible with my first home server I have been wanting to setup a CD process for my ansible playbooks, for a while I had a jenkins server setup to do just this but it just wasn’t great. Jenkins has very minimal ansible support and what it has is very raw. It feels a lot like I am just concatenating commands together and has no support for anything fun like dynamic inventories and such. After doing a little more research I found a tool called Ansible Tower. Tower is an enterprise tool made by Red Hat themselves to run ansible and the best part is it has an upstream open source version called AWX and once I found this I knew I was in love. AWX is able to dynamically pull inventories from places like aws and azure or even a git repo and if its not builtin you can write scripts to pull inventories yourself. It securely stores credentials and can automagically inject them into jobs. You can create templates for jobs that ask questions to fill variables for ansible. I could list off hundreds of amazing things that AWX does but if you’re at all interested go check it out for yourself.
…DNS via Ansible
I manage all my self hosted services with ansible (More about that in a future
post, but for now just go check out github.com/kevindurb/infra) and up until
recently ive recently needed to go to three different places
to update dns records to add a new subdomain record for a new docker container
ive just deployed (ex. homeassistant.example.com). I use cloudflare for my dns
so I would start by creating a new A record on cloudflare.com. After that
since im hosting all my services from my home internet provider I would need to
go to my router (OPNSense… Another future post…) and add a dynamic dns
updater record to update cloudflare when my home ip address changed. Lastly I
use traefik for a reverse proxy so i would add it there as well. This is a lot
of different locations and every time i would add a new service I would always
forget at least one of them…
Documenting projects by adding another project...
I enjoy projects. Projects are my way of being creative and my outlet to fuel my need to learn new things! But i have a problem… I tend to have a lot of projects going on at the same time. Projects of all different sizes, from quick projects that only take a couple hours to projects that are on going over years (I guess those would be more often named hobbies?). See I love to learn things, all kinds of things, and my projects tend to be how I learn things.
…