File tree Expand file tree Collapse file tree
.github/actions/configure-apt Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2525 Acquire::ForceIPv4 "true";
2626 EOF
2727
28+ # GitHub-hosted Ubuntu runner images can include the git-core PPA.
29+ # It is not needed for CI and can make apt update fail when Launchpad
30+ # times out.
31+ if [ -d /etc/apt/sources.list.d ]; then
32+ while IFS= read -r -d '' SOURCE_FILE; do
33+ if sudo grep -Eq 'ppa\.launchpadcontent\.net/git-core/ppa|git-core/ppa' "${SOURCE_FILE}"; then
34+ echo "Removing git-core PPA apt source: ${SOURCE_FILE}"
35+ sudo rm -f "${SOURCE_FILE}"
36+ fi
37+ done < <(
38+ sudo find /etc/apt/sources.list.d -maxdepth 1 -type f \
39+ \( -name '*.list' -o -name '*.sources' \) -print0
40+ )
41+ fi
42+
2843 # Ordered list of Ubuntu archive mirrors close to Pittsburgh, PA
2944 # (Teraswitch datacenter), with reliable fallbacks. The deb822
3045 # sources format supports multiple URIs per source, and apt will
You can’t perform that action at this time.
0 commit comments