In this section we will deploy a Kubernetes control plane and worker node on a single server using Rancher K3s. The use of K3s allows a very simple Kubernetes cluster install appropriate for single server production and lab environments.
curl -sfL https://get.k3s.io | INSTALL_K3S_EXEC="--disable=traefik" sh -s -
mkdir ~/.kube
sudo cat /etc/rancher/k3s/k3s.yaml | tee ~/.kube/config >/dev/null
kubectl get nodes
kubectl get nodes
NAME STATUS ROLES AGE VERSION
ip-172-31-3-111 Ready control-plane,master 3m4s v1.25.6+k3s1
kubectl create ns akash-services
kubectl label ns akash-services akash.network/name=akash-services akash.network=true
kubectl create ns ingress-nginx
kubectl label ns ingress-nginx app.kubernetes.io/name=ingress-nginx app.kubernetes.io/instance=ingress-nginx
kubectl create ns lease
kubectl label ns lease akash.network=true
To uninstall K3s follow this link