“docker pull” certificate signed by unknown authority

后端 未结 8 1936
灰色年华
灰色年华 2020-12-29 04:01

I was trying to pull a docker image from a docker registry but hit the following issue:

$ docker pull //          


        
相关标签:
8条回答
  • 2020-12-29 04:28

    You may need to restart the docker service to get it to detect the change in OS certificates.

    Docker does have an additional location you can use to trust individual registry server CA. You can place the CA cert inside /etc/docker/certs.d/<docker registry>/ca.crt. Include the port number if you specify that in the image tag, e.g in Linux.

    /etc/docker/certs.d/my-registry.example.com:5000/ca.crt
    

    or in Windows 10:

    C:\ProgramData\docker\certs.d\ca.crt
    
    0 讨论(0)
  • 2020-12-29 04:32

    For my case, the error was on "docker login" command.

    The solution I found for my ubuntu:

    I downloaded the crt file via firefox (lock icon in the url adress bar) and save it : ~/mydomain:1234.crt

    After that :

    cp ~/mydomain:1234.crt /usr/local/share/ca-certificates/
    update-ca-certificates
    service docker restart
    
    0 讨论(0)
提交回复
热议问题