Skip to content

Commit 6594b8c

Browse files
committed
Migrate to Ubuntu 24.04
1 parent c00096c commit 6594b8c

File tree

12 files changed

+31
-31
lines changed

12 files changed

+31
-31
lines changed

.github/workflows/docker.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,15 +71,15 @@ jobs:
7171
"ghcr.io/homebrew/ubuntu${version}:${brew_version}"
7272
"ghcr.io/homebrew/ubuntu${version}:latest"
7373
)
74-
if [[ "${version}" == "22.04" ]]; then
74+
if [[ "${version}" == "24.04" ]]; then
7575
tags+=(
7676
"ghcr.io/homebrew/brew:${brew_version}"
7777
"ghcr.io/homebrew/brew:latest"
7878
)
7979
fi
8080
elif [[ "${GITHUB_EVENT_NAME}" == "push" &&
8181
("${GITHUB_REF}" == "refs/heads/main") ]]; then
82-
if [[ "${version}" == "22.04" ]]; then
82+
if [[ "${version}" == "24.04" ]]; then
8383
tags+=("ghcr.io/homebrew/brew:main")
8484
fi
8585
tags+=("ghcr.io/homebrew/ubuntu${version}:main")

.github/workflows/tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ jobs:
329329
container: ghcr.io/homebrew/ubuntu24.04:latest
330330
- name: test-bot (Linux x86_64)
331331
runs-on: ubuntu-latest
332-
container: ghcr.io/homebrew/ubuntu22.04:main
332+
container: ghcr.io/homebrew/ubuntu24.04:main
333333
# Use Debian Old Stable for testing Homebrew's glibc support.
334334
- name: test-bot (Linux Homebrew glibc)
335335
runs-on: ubuntu-latest

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG version=22.04
1+
ARG version=24.04
22
# version is passed through by Docker.
33
# shellcheck disable=SC2154
44
FROM ubuntu:"${version}"

Library/Homebrew/dev-cmd/dispatch-build-bottle.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,12 @@ def run
6868
end
6969

7070
if args.linux?
71-
runners << "ubuntu-22.04"
71+
runners << "ubuntu-24.04"
7272
elsif args.linux_self_hosted?
7373
runners << "linux-self-hosted-1"
7474
end
7575

76-
runners << "ubuntu-22.04-arm" if args.linux_arm64?
76+
runners << "ubuntu-24.04-arm" if args.linux_arm64?
7777

7878
if runners.empty?
7979
raise UsageError, "Must specify `--macos`, `--linux`, `--linux-arm64`, or `--linux-self-hosted` option."

Library/Homebrew/dev-cmd/generate-cask-ci-matrix.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@ class GenerateCaskCiMatrix < AbstractCommand
1717
{ symbol: :sequoia, name: "macos-15-intel", arch: :intel } => 1.0,
1818
}.freeze, T::Hash[T::Hash[Symbol, T.any(Symbol, String)], Float])
1919
X86_LINUX_RUNNERS = T.let({
20-
{ symbol: :linux, name: "ubuntu-22.04", arch: :intel } => 1.0,
20+
{ symbol: :linux, name: "ubuntu-24.04", arch: :intel } => 1.0,
2121
}.freeze, T::Hash[T::Hash[Symbol, T.any(Symbol, String)], Float])
2222
ARM_MACOS_RUNNERS = T.let({
2323
{ symbol: :sonoma, name: "macos-14", arch: :arm } => 0.0,
2424
{ symbol: :sequoia, name: "macos-15", arch: :arm } => 0.0,
2525
{ symbol: :tahoe, name: "macos-26", arch: :arm } => 1.0,
2626
}.freeze, T::Hash[T::Hash[Symbol, T.any(Symbol, String)], Float])
2727
ARM_LINUX_RUNNERS = T.let({
28-
{ symbol: :linux, name: "ubuntu-22.04-arm", arch: :arm } => 1.0,
28+
{ symbol: :linux, name: "ubuntu-24.04-arm", arch: :arm } => 1.0,
2929
}.freeze, T::Hash[T::Hash[Symbol, T.any(Symbol, String)], Float])
3030
MACOS_RUNNERS = T.let(X86_MACOS_RUNNERS.merge(ARM_MACOS_RUNNERS).freeze,
3131
T::Hash[T::Hash[Symbol, T.any(Symbol, String)], Float])
@@ -300,7 +300,7 @@ def generate_matrix(tap, labels: [], cask_names: [], skip_install: false, new_ca
300300

301301
if runner.fetch(:symbol) == :linux
302302
runner_output[:container] = {
303-
image: "ghcr.io/homebrew/ubuntu22.04:main",
303+
image: "ghcr.io/homebrew/ubuntu24.04:main",
304304
options: "--user=linuxbrew",
305305
}
306306
end

Library/Homebrew/dev-cmd/tap-new.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ def run
8383
test-bot:
8484
strategy:
8585
matrix:
86-
os: [ ubuntu-22.04, macos-15-intel, macos-26 ]
86+
os: [ ubuntu-24.04, macos-15-intel, macos-26 ]
8787
runs-on: ${{ matrix.os }}
8888
permissions:
8989
actions: read
@@ -149,7 +149,7 @@ def run
149149
jobs:
150150
pr-pull:
151151
if: contains(github.event.pull_request.labels.*.name, '<%= label %>')
152-
runs-on: ubuntu-22.04
152+
runs-on: ubuntu-24.04
153153
permissions:
154154
actions: read
155155
checks: read

Library/Homebrew/github_runner_matrix.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ def active_runner_specs_hash
9090
sig { params(arch: Symbol).returns(LinuxRunnerSpec) }
9191
def linux_runner_spec(arch)
9292
linux_runner = case arch
93-
when :arm64 then "ubuntu-22.04-arm"
93+
when :arm64 then "ubuntu-24.04-arm"
9494
when :x86_64 then ENV.fetch("HOMEBREW_LINUX_RUNNER", "ubuntu-latest")
9595
else raise "Unknown Linux architecture: #{arch}"
9696
end
@@ -99,7 +99,7 @@ def linux_runner_spec(arch)
9999
name: "Linux #{arch}",
100100
runner: linux_runner,
101101
container: {
102-
image: "ghcr.io/homebrew/ubuntu22.04:main",
102+
image: "ghcr.io/homebrew/ubuntu24.04:main",
103103
options: "--user=linuxbrew -e GITHUB_ACTIONS_HOMEBREW_SELF_HOSTED",
104104
},
105105
workdir: "/github/home",

Library/Homebrew/os.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,11 @@ def self.kernel_name
4646
::OS_VERSION = T.let(ENV.fetch("HOMEBREW_OS_VERSION").freeze, String)
4747

4848
# See Linux-CI.md
49-
LINUX_CI_OS_VERSION = "Ubuntu 22.04"
50-
LINUX_GLIBC_CI_VERSION = "2.35"
49+
LINUX_CI_OS_VERSION = "Ubuntu 24.04"
50+
LINUX_GLIBC_CI_VERSION = "2.39"
5151
LINUX_GLIBC_NEXT_CI_VERSION = "2.39" # users below this version will be warned by `brew doctor`
52-
LINUX_GCC_CI_VERSION = "12" # https://packages.ubuntu.com/jammy/gcc-12
53-
LINUX_LIBSTDCXX_CI_VERSION = "6.0.30" # https://packages.ubuntu.com/jammy/libstdc++6
52+
LINUX_GCC_CI_VERSION = "13" # https://packages.ubuntu.com/noble/gcc
53+
LINUX_LIBSTDCXX_CI_VERSION = "6.0.33" # https://packages.ubuntu.com/noble/libstdc++6
5454
LINUX_PREFERRED_GCC_COMPILER_FORMULA = T.let("gcc@#{LINUX_GCC_CI_VERSION}".freeze, String)
5555
LINUX_PREFERRED_GCC_RUNTIME_FORMULA = "gcc"
5656

Library/Homebrew/test/dev-cmd/determine-test-runners_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def get_runners(file)
1616
FileUtils.rm_f github_output
1717
end
1818

19-
let(:linux_runner) { "ubuntu-22.04" }
19+
let(:linux_runner) { "ubuntu-24.04" }
2020
# We need to make sure we write to a different path for each example.
2121
let(:github_output) { "#{TEST_TMPDIR}/github_output#{DetermineRunnerTestHelper.new.number}" }
2222
let(:ephemeral_suffix) { "-12345" }

Library/Homebrew/test/dev-cmd/generate-cask-ci-matrix_spec.rb

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -153,19 +153,19 @@
153153
{ arch: :arm, name: "macos-14", symbol: :sonoma } => 0.0,
154154
{ arch: :arm, name: "macos-15", symbol: :sequoia } => 0.0,
155155
{ arch: :arm, name: "macos-26", symbol: :tahoe } => 1.0,
156-
{ arch: :arm, name: "ubuntu-22.04-arm", symbol: :linux } => 1.0,
156+
{ arch: :arm, name: "ubuntu-24.04-arm", symbol: :linux } => 1.0,
157157
{ arch: :intel, name: "macos-15-intel", symbol: :sequoia } => 1.0,
158-
{ arch: :intel, name: "ubuntu-22.04", symbol: :linux } => 1.0,
158+
{ arch: :intel, name: "ubuntu-24.04", symbol: :linux } => 1.0,
159159
})
160160

161161
expect(generate_matrix.filter_runners(c_app_only_macos))
162162
.to eq({
163163
{ arch: :arm, name: "macos-14", symbol: :sonoma } => 0.0,
164164
{ arch: :arm, name: "macos-15", symbol: :sequoia } => 0.0,
165165
{ arch: :arm, name: "macos-26", symbol: :tahoe } => 1.0,
166-
{ arch: :arm, name: "ubuntu-22.04-arm", symbol: :linux } => 1.0,
166+
{ arch: :arm, name: "ubuntu-24.04-arm", symbol: :linux } => 1.0,
167167
{ arch: :intel, name: "macos-15-intel", symbol: :sequoia } => 1.0,
168-
{ arch: :intel, name: "ubuntu-22.04", symbol: :linux } => 1.0,
168+
{ arch: :intel, name: "ubuntu-24.04", symbol: :linux } => 1.0,
169169
})
170170
end
171171
end
@@ -196,9 +196,9 @@
196196
{ arch: :arm, name: "macos-14", symbol: :sonoma } => 0.0,
197197
{ arch: :arm, name: "macos-15", symbol: :sequoia } => 0.0,
198198
{ arch: :arm, name: "macos-26", symbol: :tahoe } => 1.0,
199-
{ arch: :arm, name: "ubuntu-22.04-arm", symbol: :linux } => 1.0,
199+
{ arch: :arm, name: "ubuntu-24.04-arm", symbol: :linux } => 1.0,
200200
{ arch: :intel, name: "macos-15-intel", symbol: :sequoia } => 1.0,
201-
{ arch: :intel, name: "ubuntu-22.04", symbol: :linux } => 1.0,
201+
{ arch: :intel, name: "ubuntu-24.04", symbol: :linux } => 1.0,
202202
})
203203
end
204204
end
@@ -208,7 +208,7 @@
208208
expect(generate_matrix.filter_runners(c_on_system_depends_on_intel))
209209
.to eq({
210210
{ arch: :intel, name: "macos-15-intel", symbol: :sequoia } => 1.0,
211-
{ arch: :intel, name: "ubuntu-22.04", symbol: :linux } => 1.0,
211+
{ arch: :intel, name: "ubuntu-24.04", symbol: :linux } => 1.0,
212212
})
213213

214214
expect(generate_matrix.filter_runners(c_on_linux_depends_on_intel))
@@ -217,19 +217,19 @@
217217
{ arch: :arm, name: "macos-15", symbol: :sequoia } => 0.0,
218218
{ arch: :arm, name: "macos-26", symbol: :tahoe } => 1.0,
219219
{ arch: :intel, name: "macos-15-intel", symbol: :sequoia } => 1.0,
220-
{ arch: :intel, name: "ubuntu-22.04", symbol: :linux } => 1.0,
220+
{ arch: :intel, name: "ubuntu-24.04", symbol: :linux } => 1.0,
221221
})
222222

223223
expect(generate_matrix.filter_runners(c_on_macos_depends_on_intel))
224224
.to eq({
225225
{ arch: :intel, name: "macos-15-intel", symbol: :sequoia } => 1.0,
226-
{ arch: :intel, name: "ubuntu-22.04", symbol: :linux } => 1.0,
227-
{ arch: :arm, name: "ubuntu-22.04-arm", symbol: :linux } => 1.0,
226+
{ arch: :intel, name: "ubuntu-24.04", symbol: :linux } => 1.0,
227+
{ arch: :arm, name: "ubuntu-24.04-arm", symbol: :linux } => 1.0,
228228
})
229229

230230
expect(generate_matrix.filter_runners(c_on_system_depends_on_mixed))
231231
.to eq({
232-
{ arch: :arm, name: "ubuntu-22.04-arm", symbol: :linux } => 1.0,
232+
{ arch: :arm, name: "ubuntu-24.04-arm", symbol: :linux } => 1.0,
233233
{ arch: :intel, name: "macos-15-intel", symbol: :sequoia } => 1.0,
234234
})
235235
end

0 commit comments

Comments
 (0)