Private Registry Configuration
Containerd can be configured to connect to private registries and use them to pull images as needed by the kubelet.
Upon startup, K3s will check to see if /etc/rancher/k3s/registries.yaml
exists. If so, the registry configuration contained in this file is used when generating the containerd configuration.
- If you want to use a private registry as a mirror for a public registry such as docker.io, then you will need to configure
registries.yaml
on each node that you want to use the mirror. - If your private registry requires authentication, uses custom TLS certificates, or does not use TLS, you will need to configure
registries.yaml
on each node that will pull images from your registry.
Note that server nodes are schedulable by default. If you have not tainted the server nodes and will be running workloads on them,
please ensure you also create the registries.yaml
file on each server as well.