Skip to content

Homelab ⚗️ ​

This project aims to build a homelab for personal testing on infrastructure, development, CI/CD, etc...

It provides a complete configuration with common web services using:

  • Ansible for infrastructure deployment (gateway and k3s cluster)
  • GitOps (ArgoCD) for Kubernetes applications deployment

It is a quick starting point for simple infrastructure needs or for testing various tools such as monitoring, alerting, automated deployment, security testing, etc...

Quickstart ​

Make sure all prerequisites are met (check the installation section if needed).

Setup directory:

sh
# Clone the repository
git clone --depth 1 https://github.com/this-is-tobi/homelab.git && cd ./homelab && rm -rf ./.git && git init

# Copy inventory example to inventory
cp -R ./ansible/inventory-example ./ansible/inventory

Infrastructure ​

Setup inventory:

Install:

sh
# Deploy gateway and K3s cluster, fetch kubeconfig
./run.sh -p ./ansible/install.yml -u -k

Kubernetes Services (GitOps) ​

Setup configuration:

Install:

sh
# Set kubectl context
kubectl config use-context homelab

# Bootstrap (or upgrade) the homelab instance
./run.sh -b homelab

Optionally pass ARGOCD_ADMIN_PASSWORD=mypass before the command to set the ArgoCD admin password explicitly. Otherwise the chart auto-generates one and the script prints it at the end.