diff --git a/.github/workflows/build-linux.yml b/.github/workflows/build-linux.yml index d90aad13c8..87a0430f80 100644 --- a/.github/workflows/build-linux.yml +++ b/.github/workflows/build-linux.yml @@ -50,11 +50,13 @@ jobs: run: | # LLVM (clang) 9 is not in Bionic's repositories so we add the official LLVM repository. if [ "${{ matrix.compiler }}" = "clang" ] && [ "${{ matrix.version }}" = "9" ]; then - # pool.sks-keyservers.net is the SKS GPG global keyserver pool + # (ipv4|ha).pool.sks-keyservers.net is the SKS GPG global keyserver pool + # ipv4 avoids potential timeouts because of crappy IPv6 infrastructure # 15CF4D18AF4F7421 is the GPG key for the LLVM apt repository # This key is not in the keystore by default for Ubuntu so we need to add it. - gpg --keyserver pool.sks-keyservers.net --recv-key 15CF4D18AF4F7421 - gpg -a --export 15CF4D18AF4F7421 | sudo apt-key add - + LLVM_KEY=15CF4D18AF4F7421 + gpg --keyserver ipv4.pool.sks-keyservers.net --recv-key $LLVM_KEY || gpg --keyserver ha.pool.sks-keyservers.net --recv-key $LLVM_KEY + gpg -a --export $LLVM_KEY | sudo apt-key add - sudo add-apt-repository "deb http://apt.llvm.org/bionic/ llvm-toolchain-bionic-9 main" fi sudo apt-get -y update diff --git a/.github/workflows/build-python.yml b/.github/workflows/build-python.yml index 724f56dda8..fbec491f21 100644 --- a/.github/workflows/build-python.yml +++ b/.github/workflows/build-python.yml @@ -61,13 +61,14 @@ jobs: - name: Install (Linux) if: runner.os == 'Linux' run: | - # LLVM (clang) 9 is not in Bionic's repositories so we add the official LLVM repository. if [ "${{ matrix.compiler }}" = "clang" ] && [ "${{ matrix.version }}" = "9" ]; then - # pool.sks-keyservers.net is the SKS GPG global keyserver pool + # (ipv4|ha).pool.sks-keyservers.net is the SKS GPG global keyserver pool + # ipv4 avoids potential timeouts because of crappy IPv6 infrastructure # 15CF4D18AF4F7421 is the GPG key for the LLVM apt repository # This key is not in the keystore by default for Ubuntu so we need to add it. - gpg --keyserver pool.sks-keyservers.net --recv-key 15CF4D18AF4F7421 - gpg -a --export 15CF4D18AF4F7421 | sudo apt-key add - + LLVM_KEY=15CF4D18AF4F7421 + gpg --keyserver ipv4.pool.sks-keyservers.net --recv-key $LLVM_KEY || gpg --keyserver ha.pool.sks-keyservers.net --recv-key $LLVM_KEY + gpg -a --export $LLVM_KEY | sudo apt-key add - sudo add-apt-repository "deb http://apt.llvm.org/bionic/ llvm-toolchain-bionic-9 main" fi sudo apt-get -y update