How I can add root CA to minikube?

前端 未结 3 1783
花落未央
花落未央 2021-02-08 21:09

My company uses it\'s own root CA and when I\'m trying to pull images. Even from a private registry I\'m getting error:

1h 3m 22 {kubelet miniku

3条回答
  •  伪装坚强ぢ
    2021-02-08 21:46

    To address:

    x509: certificate signed by unknown authority
    

    Could you please try the following suggestion from Minikube repo?

    copy the cert into the VM. The location should be:

    /etc/docker/certs.d/

    from here: https://docs.docker.com/engine/security/certificates/

    ref

    That thread also includes the following one-liner:

    cat  \
      | minikube ssh "sudo mkdir -p /etc/docker/certs.d/ && sudo tee /etc/docker/certs.d//ca.crt"
    

    The issue here is the CA Trust chain of the Linux host that needs to be updated. The easiest way is to reboot the Linux host after copying the certs into the VM, if rebooting is not an option - look for a way to update-ca-certificates.

    Just restarting the Docker Daemon will most likely not solve this issue

    Note: allowing the Docker daemon to use insecure registries means certificates aren't verified.. while this may help, it does not solve the question asked here

提交回复
热议问题