Merge pull request #30616 from thaJeztah/fix-yakkety-install

install dirmngr if needed
This commit is contained in:
Victor Vieux 2017-02-01 17:21:21 -08:00 committed by GitHub
commit 632c8dd4cf

View file

@ -462,11 +462,17 @@ do_install() {
( set -x; $sh_c 'sleep 3; apt-get install -y -q curl ca-certificates' )
curl='curl -sSL'
fi
if [ ! -e /usr/bin/gpg ]; then
if ! command -v gpg > /dev/null; then
apt_get_update
( set -x; $sh_c 'sleep 3; apt-get install -y -q gnupg2 || apt-get install -y -q gnupg' )
fi
# dirmngr is a separate package in ubuntu yakkety; see https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1634464
if ! command -v dirmngr > /dev/null; then
apt_get_update
( set -x; $sh_c 'sleep 3; apt-get install -y -q dirmngr' )
fi
(
set -x
echo "$docker_key" | apt-key add -