Index

microk8s

install kubernetes on ubuntu
sudo snap install microk8s --classic
starting and stopping the snap
snap start microk8s
snap stop microk8s
enable embedded dns server
/snap/bin/microk8s.enable dns
kubectl
/snap/bin/microk8s.kubectl
watch expressions
watch /snap/bin/microk8s kubectl get pods,services -o wide --show-labels

images

listing images in the registry
microk8s ctr image list -q
microk8s ctr image list
importing an image
microk8s ctr image import [tar-file]
kubectl run [pod] --image=[tag] --image-pull-policy IfNotPresent [command]
removing an image
microk8s ctr image remove [id]
using the built in registry
microk8s enable registry
docker build .         -t localhost:32000/[tag]
docker push               localhost:32000/[tag]
kubectl run [pod] --image localhost:32000/[tag]
documentation
https://microk8s.io/docs/registry-built-in