Homelab GitOps on Kubernetes, powered by ArgoCD and managed by Github Actions. ๐
This virtual Kubernetes build consists of a 1 machine running Proxmox with 15 cores and 48 gigs of ram. This machine will be split into 3 VMs, 1 control plane and 2 worker nodes. These virtual machines will be managed with terraform and ansible. Eventually another worker node will be added through Vagrant and managed through ansible as well.
Much of the initial cluster setup has been modified from this repo, but updated for more modern versions of Kubernetes and modified Ansible playbooks.
-
Run
virtual-k8s/promox-k8s/proxmox/terraform
against Promox server, setting up 1 control-plane and 2 worker nodes. The apply takes about 4.5 minutes.โ๏ธ Confgiruation Edits
-
In the Terraform variables.tf file, you'll want to update the the variables here with connection info to your Proxmox api.
-
You also may want to change IP address and the virtual machine specs in the main.tf file to suit your needs.
In the virtual-k8s/proxmox-k8s/proxmox/terraform/ directory, run the following.
terraform init terraform plan terraform apply
-
-
Once the Terraform apply completes we'll need to setup the Ansible inventory with the nodes we created via Terraform. virtual-k8s/proxmox-k8s/
-
This will install kubeadm and other utilities necisarry for standing up the cluster. From the virtual-k8s/proxmox-k8s/proxmox/ directory run the following.
ansible-playbook -i ansible/inventory.yaml ansible/bootstrap.yaml -K
โ ๏ธ This step will generate your first kube config, make sure to properly manage theadmin.conf
file.
- Install MetalLB through ansible, for whatever reason this works better than anything else. MetalLB
allows us to establish an IP range we can later use as `LoadBalancer`` IP addresses.
ansible-playbook -i ansible/inventory.yaml ansible/metallb.yaml -K
- Install Kube Seal, follow the README.md
- Installed ArgoCD, follow the README.md.
Cluster applications are managed through ArgoCD. Most applications target the main
branch of this
repo. For more information on setting up a new ArgoCD app, check out the local
ArgoCD README.md.
App | In Use | Auto Sync Enabled |
---|---|---|
ArgoCd | โ | โ |
Cert Manager | โ | โ |
Ingress Private | โ | โ |
Ingress Public | โ | โ |
Loki | โ๏ธ | โ๏ธ |
NFS-Client | โ | โ |
Prometheus Stack | โ | โ |
DynDNS | โ | โ |
Github Runners | โ | โ |