Skip to main content
Version: 1.13

Mirroring Private Registries

Rancher Desktop can be configured to mirror private registries using either container runtime (containerd or dockerd) via provisioning scripts or updating the registry file used by k3s. Please see the k3s documentation for further information on private registry configuration.

Below is an example provisioning script that can be used to mirror private registries.

Check if you have the override.yaml file in the path below, otherwise you can create the file in the path with the suggested provisioning commands.

Override File Path: $HOME/.local/share/rancher-desktop/lima/_config/override.yaml

Example Script:

provision:
- mode: system
script: |
#!/bin/sh
set -eux
mkdir -p /etc/rancher/k3s
cat <<EOF >/etc/rancher/k3s/registries.yaml
mirrors:
"<my.private.registry>:5000":
endpoint:
- http://<my.private.registry>:5000
EOF

After restarting the application, you can verify the script being applied using the rdctl shell command below:

rdctl shell -- cat /etc/rancher/k3s/registries.yaml