Reputation: 73
Running:
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
Produces:
Could not fetch/save url https://download.docker.com/linux/centos/docker-ce.repo to file /etc/yum.repos.d/docker-ce.repo:
[Errno 14] curl#60 - "Peer's Certificate issuer is not recognized."
Upvotes: 6
Views: 20517
Reputation: 488
Add sslverify=0
in Partiucaler repo.
If you want to add for all repos then add in /etc/yum.conf
Upvotes: 4
Reputation: 4187
Some times, when you try to add a repo in large enterprises, you are behind a network proxy. One way to find it out is to open the repo's URL in the browser and see the SSL certs. In such cases, you will have to manually trust the certificates and the entire chain. In CentOS/RHEL, I had to copy all the required certs to (take a backup of the directory, just in case):
/etc/pki/ca-trust/source/anchors/
And then run this command:
update-ca-trust extract
And now you can add the repo like so:
yum-config-manager --add-repo <url-of-the-repo>
Upvotes: 3
Reputation: 1561
I encountered this and solved it with
yum reinstall ca-certificates
Upvotes: 0