moby: Docker installer: pgp key can't be retrieved
Hello,
We are using docker for our agnostic platform, here we have been installing docker to customers’ servers about 10 times every day. The problem that about 10-20% of installation fails with error:
Setting up apt-transport-https (1.0.9.8.2) ...
+ sh -c apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --homedir /tmp/tmp.LXKiwbEf78 --no-auto-check-trustdb --trust-model always --primary-keyring /etc/apt/trusted.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-security-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-stable.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-squeeze-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-squeeze-stable.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-wheezy-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-wheezy-stable.gpg --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
gpg: requesting key 2C52609D from hkp server p80.pool.sks-keyservers.net
gpgkeys: key 58118E89F3A912897C070ADBF76221572C52609D can't be retrieved
gpg: no valid OpenPGP data found.
gpg: Total number processed: 0
can it be fixed?
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 10
- Comments: 51 (25 by maintainers)
pgp.mit.edu is another choice we can fallback to
Had the same issue, and I’m sitting behind my company’s proxy. Solved it by manually passing the proxy to apt-key:
sudo apt-key adv --keyserver-options http-proxy="http://proxy.company.com:8080/" --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
I successfully set the proxy for apt-get by creating the
/etc/apt/apt.conf.d/95proxies
file, but apparently, apt-key does not use this setting: https://bugs.launchpad.net/ubuntu/+source/software-properties/+bug/1433761.EDIT: Some users are suggesting to use
--keyserver-options http-proxy=$http_proxy
if the proxy is set as an environment variable, which seems to work fine for me as well.Hello, I tried many of the suggestions for installing on Debian Jessie. The doc https://docs.docker.com/engine/installation/linux/debian/ is still wrong The one that worked:
apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
Regards
@rishibamba 👍 thanks 😄
The below command should work, this ticket should be closed
In my case it’s below
Following worked for me,
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
you can use other keyserver, i used hkp://keyserver.ubuntu.com:80, and works
Hello, this code worked for me…
I think https://docs.docker.com/engine/installation/linux/debian/ is still wrong.
@jgleal It looks like you need to go through another path to get the key in the browser: http://p80.pool.sks-keyservers.net:11371/pks/lookup?search=0x58118E89F3A912897C070ADBF76221572C52609D&op=vindex
@bmarkovic not sure how to find it through their web-interface, but these all seem to work for me;
Will manually update it today. Sorry about this
@hbrgnr : --keyserver-options http-proxy=$http_proxy
This worked for me thanks 😃
Hello,
it seems this fix was removed from get.docker.com: https://get.docker.com/ And:
twice for today already
@thaJeztah Would you accept a patch that tries another key server besides sks-keyservers if it fails? e.g. we can fail over to keyserver.ubuntu.com.