Advanced Options¶
This guide covers advanced configuration and customisation scenarios beyond the defaults.
Adjusting Node Resources¶
Increase Worker RAM¶
For resource-intensive workloads, increase worker memory in cluster.yaml:
- name: "node01"
ip: "192.168.56.11"
memory: 4096 # 4 GB instead of default 1.5 GB
cpus: 2 # 2 CPUs instead of default 1
role: "worker"
After changing resources, destroy and recreate the affected node:
Warning
vagrant reload does not apply memory/CPU changes. You must destroy and recreate the VM.
Changing Network Configuration¶
Custom Pod CIDR¶
The default pod CIDR is 10.244.0.0/16. To use a different range:
Full Cluster Rebuild Required
Changing the pod CIDR requires destroying all VMs and re-provisioning from scratch, since it is baked into kubeadm init and the Calico configuration.
Custom Service CIDR¶
The same full-rebuild requirement applies.
Scaling the Cluster¶
Adding Worker Nodes to a Running Cluster¶
-
Add a new node entry to
cluster.yaml: -
Bring up only the new node:
The new worker will automatically find and execute the join command from the shared
/vagrantfolder.
Join Token Expiry
kubeadm join tokens expire after 24 hours. If the cluster was created more than 24 hours ago, generate a new token first:
Removing a Worker Node¶
-
Drain the node from the control plane:
-
Destroy the VM:
-
Remove or comment out the node entry in
cluster.yaml.
Changing the Calico CNI Version¶
To use a different Calico version:
Note
This requires a full cluster rebuild. The Calico manifests are downloaded from the official release URL based on this version string.
Using a Different Vagrant Box¶
To use a different base OS image:
Compatibility
The provisioning scripts are tested with ubuntu/jammy64 (22.04 LTS). Other Ubuntu versions may work but are not officially tested. Non-Ubuntu distributions are not supported in v0.1.0.
Useful kubectl Commands¶
# Detailed node information
kubectl describe node controlplane
# Resource usage (requires metrics-server, not included in v0.1.0)
kubectl top nodes
kubectl top pods -A
# Watch events in real time
kubectl get events --watch
# Get cluster information
kubectl cluster-info
# View kubeadm cluster configuration
kubectl -n kube-system get cm kubeadm-config -o yaml