Skip to content

Commit

Permalink
CI Linux: add-apt-repostitory retries
Browse files Browse the repository at this point in the history
Fetching GPG keys sometimes fails on timeout so prevent it by adding
retries with exponentially increasing intervals taken from:
<canonical/server-test-scripts#18>
(just removed bashisms)
  • Loading branch information
MartinPulec committed Nov 29, 2024
1 parent 3e04432 commit 49a16a9
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/scripts/Linux/prepare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,12 @@ sdl2_ttf_build_dep=$(get_build_deps_excl libsdl2-ttf libsdl2-dev)
sudo apt install $sdl2_mix_build_dep $sdl2_ttf_build_dep

# FFmpeg deps
sudo add-apt-repository ppa:savoury1/ffmpeg4 # openh264, new x265
for i in $(seq 10); do
[ "$i" -gt 1 ] && sleep $((2**i))
# openh264, new x265
sudo add-apt-repository --yes ppa:savoury1/ffmpeg4 && err=0 && break || err=$?
done
(exit "$err")
# for FFmpeg - libzmq3-dev needs to be ignored (cannot be installed, see run #380)
ffmpeg_build_dep=$(get_build_deps_excl ffmpeg 'libva-dev')
# shellcheck disable=SC2086 # intentional
Expand Down

0 comments on commit 49a16a9

Please sign in to comment.