Image pull over multiple K8s nodes

7/19/2020

When I create a pod, a corresponding image is pulled to the node where the pod is created

Can I have those images shared among the cluster nodes, instead of being stored locally on each node?

Thanks a lot Best Regards

-- Recruitment Expert
containers
docker
image
kubernetes

1 Answer

7/19/2020

It's possible if you have shared storage across all the Kubernetes nodes. However, it's not a good idea 🙅 since typically the place where images get stored is also the place where the container runtime stores its files when it's actually running the container. For example, if you are using Docker, everything gets stored under /var/lib/docker or in the case of containerd it's /var/lib/containerd

So in summary, it's possible with shared files/cluster file systems like NFS, Ceph, Glusterfs, AWS EFS, etc, but it's not a good idea in my opinion 🚫.

Update (@BMitch):

Make sure that the container storage driver you are using supports the filesystem that you are using.

✌️

-- Rico
Source: StackOverflow