Skip to content

Conversation

@chrisd8088
Copy link
Member

@chrisd8088 chrisd8088 commented Oct 16, 2024

As of Ubuntu 24.04, the primary list of sources for APT moved to the /etc/apt/sources.list.d/ubuntu.sources file instead of the legacy /etc/apt/sources.list file, and was rewritten to make use of the deb822 format, which is based on RFC 822. From the Ubuntu 24.04 release notes:

The sources configuration for Ubuntu has moved from /etc/apt/sources.list to /etc/apt/sources.list.d/ubuntu.sources in the more featureful deb822 format, aligning with PPAs that already migrated to deb822 last year.

As GitHub Actions are now migrating their ubuntu-latest runners to Ubuntu 24.04, per actions/runner-images#10636, we need to adjust the script our CI jobs use to build custom versions of Git so that it is able to fetch the necessary source packages it requires.

We therefore update the script so it checks for the presence of an /etc/apt/sources.list.d/ubuntu.sources file, and if that exists, adds the deb-src archive type to the Types: lines of the entries in that file; otherwise, the script adds the deb-src type to the entries in the /etc/apt/sources.list file as it did previously.

A successful run of our Build with latest Git and Build with earliest Git CI jobs on an ubuntu-24.04 runner demonstrates these changes work as expected.

As of Ubuntu 24.04, the primary list of sources for APT moved to the
/etc/apt/sources.list.d/ubuntu.sources file instead of the legacy
/etc/apt/sources.list file, and was rewritten to make use of the
deb822 format, which is based on RFC 822:

  https://discourse.ubuntu.com/t/ubuntu-24-04-lts-noble-numbat-release-notes/39890#deb822-sources-management
  https://discourse.ubuntu.com/t/spec-apt-deb822-sources-by-default/29333
  https://manpages.ubuntu.com/manpages/noble/man5/sources.list.5.html
  https://manpages.debian.org/bookworm/dpkg-dev/deb822.5.en.html

As GitHub Actions are now migrating their "ubuntu-latest" runners
to Ubuntu 24.04, we need to adjust the script our CI jobs use to build
custom versions of Git so that it is able to fetch the necessary
source packages it requires.  We therefore update the script so it
checks for the presence of an /etc/apt/sources.list.d/ubuntu.sources
file, and if that exists, adds the "deb-src" archive type to the
"Types:" lines of the entries in that file; otherwise, the script
adds the "deb-src" type to the entries in the /etc/apt/sources.list
file as it did previously.
@chrisd8088 chrisd8088 requested a review from a team as a code owner October 16, 2024 17:49
Copy link
Member

@bk2204 bk2204 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well explained, as usual.

@chrisd8088 chrisd8088 merged commit 3fd88b1 into git-lfs:main Oct 16, 2024
@chrisd8088 chrisd8088 deleted the update-ubuntu-git-build branch October 16, 2024 21:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants