Tyler's Site

Abstract

I have been wanting to learn more about coding and DevOps recently. While I am not currently very good at either right now, I certianly have the tools to learn more and improve. This led me to wanting to make a project that assists in creating and managing virtual machines (VMs) and containers on my home server that runs FreeBSD. While it is easy enough to SSH into the box and do anything that I need to, it would be nice to have a web interface that I can login to and manage things that way. It would be even nicer to have one click app deployments similar to what a VPS provider like Linode can do. So, let’s try to build one.

Ideas

Obviously this is not going to be a project that can be done, at least not for me, in one blog post. There is quite a bit of learning that I will need to do, and a few different kinds of problems that I will need to solve. That is on top of all the design and architect decisions that need to be made before actually creating it. I do have a few things in mind that I would like to work towards:

These goals feel rather ambitious right now, but this is more of a learning project than anything else. If I fail, hopefully I learned something. If I don’t fail, maybe I will have made something really cool.

Setting Up Dev Environment

Before I really get started trying to do any coding, I need to get an environment set up to work in. Since I am targeting for FreeBSD, I will need a FreeBSD box to test in. So I will be setting up a FreeBSD 13.2 VM with nested virtualization enabled. Enabliing nested virtualization is pretty easy to get working, assuming your hardware supports it:

# For intel processors
# Unloads KVM kernel module
$ sudo modprobe -r kvm_intel
# and re-loads it with nested virtualization enabled
$ sudo modprobe kvm_intel nested=1
# For AMD processors
# Unloads KVM kernel module
$ sudo modprobe -r kvm_amd
# and re-loads it with nested virtualization enabled
$ sudo modprobe kvm_amd nested=1

This change can be made permanet by editing /etc/modeprobe.d/kvm.conf. Just add either options kvm_intel nested=1 on Intel systems, or options kvm_amd nested=1 on AMD systems.

From there, just install FreeBSD 13.2 as normal and start hacking away on the project. I will be giving updates on the project as enough interesting stuff to write about comes up.