From 93de997d1249830cba73cb6c07f1e8dd54776fa0 Mon Sep 17 00:00:00 2001 From: Luca Boccassi Date: Tue, 5 Apr 2022 22:11:55 +0100 Subject: [PATCH] semaphoreci: check keys.opengpgp.org first Always resolves and it's faster than the others + for keyserver in "" "keys.gnupg.net" "keys.openpgp.org" "keyserver.ubuntu.com" + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 1 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 4 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 9 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 16 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 25 + for keyserver in "" "keys.gnupg.net" "keys.openpgp.org" "keyserver.ubuntu.com" + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 --keyserver keys.gnupg.net Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 1 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 --keyserver keys.gnupg.net Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 4 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 --keyserver keys.gnupg.net Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 9 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 --keyserver keys.gnupg.net Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 16 + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 --keyserver keys.gnupg.net Setting up the GPG keyring ERROR: Unable to fetch GPG key from keyserver lxc-create: bullseye-amd64: lxccontainer.c: create_run_template: 1617 Failed to create container from template lxc-create: bullseye-amd64: tools/lxc_create.c: main: 327 Failed to create container bullseye-amd64 + sleep 25 + for keyserver in "" "keys.gnupg.net" "keys.openpgp.org" "keyserver.ubuntu.com" + for retry in {1..5} + sudo lxc-create -n bullseye-amd64 -t download -- -d debian -r bullseye -a amd64 --keyserver keys.openpgp.org Setting up the GPG keyring Downloading the image index Downloading the rootfs --- .semaphore/semaphore-runner.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.semaphore/semaphore-runner.sh b/.semaphore/semaphore-runner.sh index 6ccf271a82..7ed6773213 100755 --- a/.semaphore/semaphore-runner.sh +++ b/.semaphore/semaphore-runner.sh @@ -21,7 +21,7 @@ UBUNTU_RELEASE="$(lsb_release -cs)" create_container() { # Create autopkgtest LXC image; this sometimes fails with "Unable to fetch # GPG key from keyserver", so retry a few times with different keyservers. - for keyserver in "" "keys.gnupg.net" "keys.openpgp.org" "keyserver.ubuntu.com"; do + for keyserver in "keys.openpgp.org" "" "keyserver.ubuntu.com" "keys.gnupg.net"; do for retry in {1..5}; do sudo lxc-create -n "$CONTAINER" -t download -- -d "$DISTRO" -r "$RELEASE" -a "$ARCH" ${keyserver:+--keyserver "$keyserver"} && break 2 sleep $((retry*retry))