k3s
k3s
see also some kubernetes / k8s stuff:
cleanup unused images
that’s how things start. cleanup unused images, sometimes I need to do that and besides what kubernetes things since other stuff is also running on the same system (I know).
list images:
sudo k3s crictl imagesdelete images not currently in use:
sudo k3s crictl rmi --prunedelete individual image
sudo k3s crictl rmi docker.pkg.dev/package/packagename:latestimport docker / container image
docker save localhost/shaarli | sudo k3s ctr images import -make sure to set the deployment imagePullPolicy to Never:
how to use it in a kubernetes yaml file:
containers:
- image: localhost/shaarli:latest
imagePullPolicy: Never