Cannot login private docker registry (x509: certificate signed by unknown authority)

I’m having a problem creating a docker image and pushing to my private docker registry. I tried to force my server.crt certificate file and performed an update certificates operation. However, it seems that everything still leads to the final result “x509: certificate signed by unknown authority”.

  • Here is my sample configuration
  • run:
    name: Authentication and push private hub
    command: |
    sudo mkdir -p /usr/local/share/ca-certificates/
    sudo cp server.crt /usr/local/share/ca-certificates/server.crt
    sudo update-ca-certificates
    docker login --username $DOCKER_USER --password $DOCKER_PASS
    docker push$BRANCH

Please give me a help. I am very grateful to you for that

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.