You can configure your cluster to authenticate with registries (such as Docker Hub), and add registries, by defining each in the ClusterConfiguration .spec.imageRegistries list in the cluster.yaml file.
For Kommander, to add credentials for Docker Hub, set the options in your cluster.yaml as follows:
- name: kommander
enabled: true
values: |
kommander-federation:
utilityApiserver:
extraArgs:
docker-registry-url: "https://registry-1.docker.io"
docker-registry-username: <username>
docker-registry-password: <password>
-
Apply the changes to your cluster. Enter the following command:
konvoy up -
Confirm the changes made to the cluster. You will need to ssh into any of your cluster’s nodes. From there, enter the following command to check the contents of the
containerdconfiguration file:$ cat /etc/containerd/config.tomlYou should see the output that contains your Docker Hub credentials:
... [plugins."io.containerd.grpc.v1.cri".registry] [plugins."io.containerd.grpc.v1.cri".registry.mirrors] [plugins."io.containerd.grpc.v1.cri".registry.mirrors."docker.io"] endpoint = ["https://registry-1.docker.io"] [plugins."io.containerd.grpc.v1.cri".registry.configs] [plugins."io.containerd.grpc.v1.cri".registry.configs."registry-1.docker.io".auth] username = "<username>" password = "<password>" auth = "" identitytoken = "" ...
For more information on configuring imageRegistries in the cluster.yaml, refer to the API documentation (v1beta2) documentation.
Kommander Documentation