I originally added the `du5t1n.me/storage` label to the x86_64 nodes and configured Longhorn to only run on nodes with those labels because I thought that was the correct way to control where volume replicas are stored. It turns out that this was incorrect, as it prevented Longhorn from running on non-matching nodes entirely. Thus, any machine that was not so labeled could not access any Longhorn storage volumes. The correct way to limit where Longhorn stores volume replicas is to enable the `create-default-disk-labeled-nodes` setting. With this setting enabled, Longhorn will run on all nodes, but will not create "disks" on them unless they have the `node.longhorn.io/create-default-disk` label set to `true`. Nodes that do not have "disks" will not store volume replicas, but will run the other Longhorn components and can therefore access Longhorn volumes. Note that changing the "default settings" ConfigMap does not change the setting once Longhorn has been deployed. To update the setting on an existing installation, the setting has to be changed explicitly: ```sh kubectl get setting -n longhorn-system -o json \ create-default-disk-labeled-nodes \ | jq '.value="true"' \ | kubectl apply -f - ``` |
||
---|---|---|
autoscaler | ||
docker-distribution | ||
dynk8s-provisioner | ||
hudctrl | ||
ingress | ||
jenkins | ||
phpipam | ||
prometheus_speedtest | ||
setup | ||
storage | ||
README.md |
README.md
Dustin's Kubernetes Cluster
This repository contains resources for deploying and managing my on-premises Kubernetes cluster
Cluster Setup
The cluster primarily consists of libvirt/QEMU+KVM virtual machines. The Control Plane nodes are VMs, as are the x86_64 worker nodes. Eventually, I would like to add Raspberry Pi or Pine64 machines as aarch64 nodes.
All machines run Fedora, using only Fedora builds of the Kubernetes components
(kubeadm
, kubectl
, and kubeadm
).
See Cluster Setup for details.
Jenkins Agents
One of the main use cases for the Kubernetes cluster is to provide dynamic agents for Jenkins. Using the Kubernetes Plugin, Jenkins will automatically launch worker nodes as Kubernetes pods.
See Jenkins Kubernetes Integration for details.
Persistent Storage
Persistent storage for pods is provided by Longhorn. Longhorn runs within the cluster and provisions storage on worker nodes to make available to pods over iSCSI.
See Persistent Storage Using Longorn for details.