I have an issue of installing Docker on ubuntu 18.04
When I try the following lines I get an https error due to there being no http version and we are behind a company proxy so it fails.
sudo add-apt-repository "deb [arch=amd64] bionic stable"
sudo apt update
Fails with.
Certificate verification failed: The certificate is NOT trusted. The certificate issuer is unknown. Could not handshake: Error in the certificate verification.
Is there an alternative way to install even for a one of version using curl or wget?
Is there a way of bypassing a proxy in the apt conf to tell it to ignore the certificate error?
Edit I tried with the [trusted=yes] flag but this didn't work I think because this reverts to http and there is no http URL.
Err:6 bionic Release
Certificate verification failed: The certificate is NOT trusted. The certificate issuer is unknown. Could not handshake: Error in the certificate verification.
E: The repository ' bionic Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
1 Answer
From docker's site here are the steps to install docker:
Update apt package index
sudo apt-get update
Install the requirements for docker
sudo apt-get install \
apt-transport-https \
ca-certificates \
curl \
gnupg-agent \
software-properties-common
Add Docker's GPG key
curl -fsSL | sudo apt-key add -
Note: You should check the key if it's correct. (Follow the link)
Add Docker's repository
sudo add-apt-repository \
"deb [arch=amd64] \
$(lsb_release -cs) \
stable"
Then update with apt
sudo apt-get update
And now you can install docker with apt
sudo apt-get install docker-ce docker-ce-cli containerd.io