How can you validate that registries.yaml is set properly?



  • I've set up my /etc/rancher/k3s/registries.yaml, how can I confirm it works without doing

    k3s kubectl run c1 --image docker.io/perl:5.30
    k3s kubectl logs --follow=true c1
    sleep 1
    k3s kubectl delete pod c1
    

    Is there a more efficient way to test registry authentication for images than having to use k3s run?



  • The /etc/rancher/k3s/registries.yaml is read by https://devops.stackexchange.com/q/16152/18965 . You can validate it works properly with a command like this,

    sudo k3s crictl pull     docker.io/alpine:3
    sudo k3s ctr images pull docker.io/library/alpine:3
    



Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2