Repository for managing a Kubernetes cluster through GitOps workflows.
Powered by Proxmox VE, Terraform, Talos, Argo CD, and Sealed Secrets. Kept up to date with Renovate. Includes a healthy dose of automation and the occasional 3-letter commit message.
This repository hosts the IaC (Infrastructure as Code) configuration for my homelab.
The homelab runs on Proxmox VE hypervisor nodes, with VMs provisioned using Terraform.
- helios β a Talos Kubernetes cluster (control plane + workers)
- atlas β an Ubuntu VM used as a file server for media storage and Longhorn backups
All cluster workloads are managed via GitOps with Argo CD and an ApplicationSet that auto-syncs from this repository. Secrets are encrypted in-repo with SOPS + age for shared/bootstrap material and selected bootstrap secrets, while Sealed Secrets handles Kubernetes-native secret workflows for application manifests.
Namespaces also carry Pod Security Admission labels. General-purpose namespaces (argocd, auth, and services) enforce the Kubernetes baseline profile and emit restricted warnings/audits, while infrastructure namespaces that still need elevated access (monitoring, network, storage, and velero) keep permissive enforcement and emit baseline warnings/audits so exceptions remain visible without breaking workloads.
-
Prepare the cluster-ops toolbox.
Follow
docs/operations/cluster-ops-toolbox.mdto install the required CLI tools. Once the tools are present, validate the workstation toolchain from the repo root with:.\scripts\initialize-ClusterOps.ps1 -SkipConfigImport
-
Create Terraform variables in
terraform/helios(and optionallyterraform/atlas). Use the provided.examplefiles as a reference. -
Deploy the Talos cluster using Terraform:
cd terraform/helios
terraform init
terraform apply- Import dedicated kubeconfig and talosconfig files for day-2 work:
.\scripts\initialize-ClusterOps.ps1This writes dedicated config files to ~/.kube/orbit-helios.config and ~/.talos/orbit-helios.config, then exports KUBECONFIG and TALOSCONFIG for the current shell.
- Bootstrap the cluster (creates namespaces, reapplies
sealed-secret-backup.yamlinto thesecretsnamespace, installs ArgoCD and ArgoCD-Apps):
.\scripts\new-Cluster.ps1ArgoCD will automatically sync all remaining applications from the repository. Retrieve the initial admin password with:
.\scripts\get-ArgoPassword.ps1- Creating a sealed value for a specific secret key:
.\scripts\new-SealedSecret.ps1 -password <value> -namespace <ns> -secretName <name> -key <secretKey>- Edit a SealedSecret file using your default editor (sops-like flow):
.\scripts\edit-SealedSecret.ps1 -FilePath <path-to-sealed-secret.yaml>This decrypts the file to a temporary manifest, opens it in $VISUAL/$EDITOR (falls back to vi), and reseals it back to the original file when the editor exits.
The script automatically preserves secret name, namespace, and scope (strict, namespace-wide, cluster-wide) from the existing manifest.
- Backing up Sealed Secrets recovery keys from the
secretsnamespace:
.\scripts\backup-SealedSecret.ps1Use -controllerNamespace <namespace> if your controller is not running in the repo default secrets namespace.
-
Configure Velero Azure credentials (create a
velero-credentialssecret with acloudkey in theveleronamespace that includes your Azure subscription ID, then updatekubernetes/velero/velero/values.yamlwith your Azure storage account and resource group).The repo keeps this credential as a SOPS-encrypted secret manifest at
kubernetes/velero/velero/velero-credentials.sops.yaml; prefer updating that file instead of introducing a second secret-management pattern. -
Restore Velero backups during onboarding (optional):
.\scripts\new-Cluster.ps1 -RestoreVelero -VeleroSchedule dailyUse the repo's cluster-ops helpers from a dedicated admin workstation shell:
.\scripts\initialize-ClusterOps.ps1
.\scripts\get-ClusterOpsSnapshot.ps1 -IncludeVeleroinitialize-ClusterOps.ps1validates the CLI toolchain and imports dedicatedkubectl/talosctlconfigs from the Terraform outputs.get-ClusterOpsSnapshot.ps1gives a quick day-2 status view for nodes, Argo CD applications, unhealthy pods, and optional Velero resources.backup-SealedSecret.ps1defaults to the repo's activesecretsnamespace, matching the checked-in Sealed Secrets key backup manifest.docs/operations/cluster-ops-toolbox.mdincludes the Grafana access flow for the repo-managed monitoring stack.docs/operations/storage-dr.mdcaptures the repo's current Longhorn replica policy plus the Velero backup and restore drill workflow.
- Public HTTP exposure should use Traefik
IngressRouteresources on thewebsecureentrypoint. - External TLS currently terminates in Traefik via the shared
letsencryptACME resolver;cert-manager'sinternal-selfsignedissuer is reserved for cluster-internal certificates. - Admin and operator-facing routes should usually attach the shared
network/oauth2-proxy-authmiddleware, withnetwork/local-onlyavailable for LAN-only surfaces when needed. - The
helm-charts/generic-servicechart now exposesingress.entryPoints,ingress.middlewares, andingress.tlssettings so new services can follow the same Traefik and access pattern without copy/paste edits.
End-user facing applications
| Logo | Name | Description |
|---|---|---|
| Hello-World | Example and template application for the repository | |
| Home Assistant | Open-source home automation platform (proxied via nginx). | |
| Memos | Lightweight, self-hosted note-taking service. | |
| AIOStreams | All-in-one Stremio addon aggregator and proxy. | |
| Nexus3 | Universal artifact repository manager. | |
| Obsidian Sync | Self-hosted sync backend for Obsidian (proxied via nginx). | |
| RoomCtrlScraper | Custom service to scrape and manage room control data. |
Ingress, DNS, and identity services
| Logo | Name | Description |
|---|---|---|
| authentik | Identity provider enabling single sign-on (SSO) and centralized user management. | |
| Cert Manager | Manages TLS certificates for secure communication within Kubernetes. | |
| MetalLB | Load-balancer implementation for bare metal Kubernetes clusters. | |
| Traefik | Cloud-native reverse proxy and ingress controller for Kubernetes. | |
| Traefik CRDs | Custom Resource Definitions required by Traefik. |
Persistent storage services
| Logo | Name | Description |
|---|---|---|
| Longhorn | Cloud-native distributed block storage for Kubernetes. | |
| Velero | Scheduled backups with retention and Azure off-site storage. | |
| Syncthing | Continuous file synchronization between devices. |
Secret management
| Logo | Name | Description |
|---|---|---|
| Sealed Secrets | Encrypts Kubernetes secrets for safe storage in Git. |
Foundation components for running and deploying applications in my cluster
| Logo | Name | Description |
|---|---|---|
| Argo CD | GitOps tool for continuous delivery and Kubernetes application management. | |
| kube-prometheus-stack | Cluster monitoring foundation with Prometheus, Alertmanager, Grafana, and Traefik/Velero/Longhorn hooks. | |
| Renovate | Automates dependency and container image updates via pull requests. | |
| Intel QuickSync | Intel GPU device plugin enabling hardware-accelerated video transcoding in Kubernetes. |
| Name | Device | CPU | RAM | Storage | Purpose |
|---|---|---|---|---|---|
| pve1 | Aoostar R7 | AMD Ryzen 7 5825U | 48 GB DDR4 SO-DIMM | 8TB HDD + 2TB SSD | Compute/General |