Access local docker images with k3s

8/21/2019

Is there any way to access local docker images directly (without using 'docker save') with k3s?

Like minikube accesses local docker images after running this command

eval $(minikube docker-env)

A little bit of background.

I have set up a machine using Ubuntu 19.04 as 'master' and raspberry pi as 'worker' using k3s. Now, I want to use a local image to create a deployment on the worker node.

Update

Adding screenshot as said in the comment below.

Screenshot for the image listings

enter image description here

-- Naveed
docker
k3s
kubernetes

1 Answer

5/8/2020

You can start k3s like this sudo k3s server --docker which will use host's Docker rather than containerd. This will make all local images available to k3s and if your ImagePullPolicy is IfNotPresent k3s will use it rather than trying to pull it.

-- foobarto
Source: StackOverflow