Skip to content

fix: upgrade Docker image from Ubuntu 22.04 to 24.04 - #9002

Closed
timosachsenberg wants to merge 2 commits into
developfrom
test/docker-ubuntu-24.04
Closed

timosachsenberg wants to merge 2 commits into
developfrom
test/docker-ubuntu-24.04

Conversation

@timosachsenberg

@timosachsenberg timosachsenberg commented Mar 26, 2026 •

Copy link
Copy Markdown
Contributor

Ubuntu 22.04 ships Boost 1.74 which does not support the BOOST_PROCESS_USE_STD_FS macro, causing unresolved boost::filesystem symbols when linking TOPP tools. Ubuntu 24.04 ships Boost 1.83 where the macro works correctly.

  • Base and runtime images: ubuntu:22.04 → ubuntu:24.04
  • Boost packages: version-pinned 1.74 → unversioned (1.83)
  • Arrow APT source: jammy → noble
  • Runtime Boost libs: 1.74-dev → 1.83.0

Description

Checklist

  • Make sure that you are listed in the AUTHORS file
  • Add relevant changes and new features to the CHANGELOG file
  • I have commented my code, particularly in hard-to-understand areas
  • New and existing unit tests pass locally with my changes
  • Updated or added python bindings for changed or new classes (Tick if no updates were necessary.)

How can I get additional information on failed tests during CI

Click to expand If your PR is failing you can check out

Advanced commands (admins / reviewer only)

Click to expand
  • /reformat (experimental) applies the clang-format style changes as additional commit. Note: your branch must have a different name (e.g., yourrepo:feature/XYZ) than the receiving branch (e.g., OpenMS:develop). Otherwise, reformat fails to push.
  • setting the label "NoJenkins" will skip tests for this PR on jenkins (saves resources e.g., on edits that do not affect tests)
  • commenting with rebuild jenkins will retrigger Jenkins-based CI builds

⚠️ Note: Once you opened a PR try to minimize the number of pushes to it as every push will trigger CI (automated builds and test) and is rather heavy on our infrastructure (e.g., if several pushes per day are performed).

Summary by CodeRabbit

  • Chores
    • Updated Docker build environment to Ubuntu 24.04.
    • Upgraded Boost development packages to the 1.83 series.
    • Switched Apache Arrow package source to the newer release for runtime compatibility.
    • Improved package installation and cleanup steps to reduce leftover artifacts and ensure certificate/wget tooling for downloads.

@coderabbitai

coderabbitai Bot commented Mar 26, 2026 •

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

Dockerfile stages updated from Ubuntu 22.04 to 24.04; Boost dev packages unpinned in the base stage and upgraded in the library stage; Apache Arrow APT installer switched from Jammy to Noble; runtime Arrow/Parquet packages and wget/apt cleanup were added.

Changes

Cohort / File(s) Summary
Image base change
dockerfiles/Dockerfile
Build stages base and library switched from ubuntu:22.04 to ubuntu:24.04; software.version label updated to reflect Ubuntu 24.04.
Boost packages
dockerfiles/Dockerfile
base stage: removed version-pinned libboost-*-1.74-dev in favor of unpinned libboost-*-dev; library stage: upgraded Boost dev packages to 1.83.0-specific names.
Arrow / Parquet installer and runtime
dockerfiles/Dockerfile
Replaced Jammy .deb installer with Noble .deb for Apache Arrow (download/cleanup filenames updated); library stage now installs explicit runtime packages libarrow2300 and libparquet2300.
Tools & cleanup
dockerfiles/Dockerfile
Added ca-certificates and wget where required; removed downloaded .deb files and performed apt purge/autoremove and cleanup; trimmed trailing whitespace on one dependency line.

Poem

🐰 I hopped from twenty-two to twenty-four,
New Boost leaves scattered on the floor,
Arrow turned noble, packages neat,
Wget fetched, then swept with tiny feet,
A rabbit hums—containers are sweet!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and accurately summarizes the main change: upgrading Docker images from Ubuntu 22.04 to 24.04, which is the primary objective and focus of the entire changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch test/docker-ubuntu-24.04

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
dockerfiles/Dockerfile (1)

14-14: Pin ubuntu:24.04 by digest for build reproducibility.

The 24.04 tag is mutable, so rebuilding this image later could pull a different rootfs snapshot. For a PR focused on upgrading the container toolchain, pinning both FROM lines to their manifest-list digest ensures consistent builds across time.

Resolve the current digest (e.g., via docker inspect --format='{{index .RepoDigests 0}}' ubuntu:[email protected] on a system with Docker access or query the Docker Registry API) and update:

-FROM ubuntu:24.04 AS base
+FROM ubuntu:24.04@sha256:<resolved-digest> AS base

Also applies to: 159-159

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile` at line 14, Pin the base image by replacing the
mutable tag "FROM ubuntu:24.04 AS base" with its immutable manifest digest
(e.g., "FROM ubuntu@sha256:... AS base"); resolve the correct digest via docker
inspect or the Registry API and update that FROM line and the other identical
FROM at the specified location (the second "FROM ubuntu:24.04" reference) so
both FROM instructions use the same ubuntu@sha256:... digest for reproducible
builds.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@dockerfiles/Dockerfile`:
- Around line 56-59: Replace the floating wget/install steps for
apache-arrow-apt-source-latest-noble.deb with a checksum-verified flow: obtain
the package SHA256 locally, add that constant to the Dockerfile, download the
file with the existing wget command, verify the file against the SHA256 (failing
the build on mismatch), and only then install the package (using dpkg -i or
apt-get install ./apache-arrow-apt-source-latest-noble.deb) and remove the file;
update the lines referencing apache-arrow-apt-source-latest-noble.deb to include
the verification step so builds are reproducible and fail fast on checksum
mismatch.

---

Nitpick comments:
In `@dockerfiles/Dockerfile`:
- Line 14: Pin the base image by replacing the mutable tag "FROM ubuntu:24.04 AS
base" with its immutable manifest digest (e.g., "FROM ubuntu@sha256:... AS
base"); resolve the correct digest via docker inspect or the Registry API and
update that FROM line and the other identical FROM at the specified location
(the second "FROM ubuntu:24.04" reference) so both FROM instructions use the
same ubuntu@sha256:... digest for reproducible builds.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: c6c1a7eb-9877-4415-a42f-040286eb98f2

📥 Commits

Reviewing files that changed from the base of the PR and between aa7ecda and cdd5b25.

📒 Files selected for processing (1)
  • dockerfiles/Dockerfile

Comment thread dockerfiles/Dockerfile
Comment on lines +56 to +59
&& wget https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb \
&& apt-get install -y --no-install-recommends ./apache-arrow-apt-source-latest-noble.deb \
&& apt-get update && apt-get install -y --no-install-recommends --no-install-suggests libparquet-dev \
&& rm apache-arrow-apt-source-latest-jammy.deb
&& rm apache-arrow-apt-source-latest-noble.deb

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

python <<'PY'
import hashlib
import urllib.request

url = "https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb"
digest = hashlib.sha256()

with urllib.request.urlopen(url) as resp:
    while True:
        chunk = resp.read(1024 * 1024)
        if not chunk:
            break
        digest.update(chunk)

print(digest.hexdigest())
PY

Repository: OpenMS/OpenMS

Length of output: 2638


🏁 Script executed:

# Locate and examine the Dockerfile
find . -name "Dockerfile" -type f | head -20

Repository: OpenMS/OpenMS

Length of output: 108


🏁 Script executed:

# Read the Dockerfile to verify the code snippet and context
cat -n dockerfiles/Dockerfile | sed -n '50,65p'

Repository: OpenMS/OpenMS

Length of output: 846


🏁 Script executed:

# Check if there are any references to Arrow packages or checksums elsewhere in the codebase
rg -i "apache-arrow|arrow-apt|sha256" --type dockerfile --type bash --type sh

Repository: OpenMS/OpenMS

Length of output: 91


🏁 Script executed:

# Look for any documentation or comments about Arrow package versioning
rg -i "noble|ubuntu|apt-source" dockerfiles/ -A 2 -B 2

Repository: OpenMS/OpenMS

Length of output: 1484


Pin the Arrow APT source package with a SHA256 checksum.

The floating apache-arrow-apt-source-latest-noble.deb filename can change without warning. Capture the current package's SHA256 hash and add verification to the Dockerfile to ensure reproducible builds:

+ARG ARROW_APT_SOURCE_SHA256=<resolved-sha256>
...
   && wget https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb \
+  && echo "${ARROW_APT_SOURCE_SHA256}  apache-arrow-apt-source-latest-noble.deb" | sha256sum -c - \
   && apt-get install -y --no-install-recommends ./apache-arrow-apt-source-latest-noble.deb \

To obtain the checksum, download and hash the artifact locally.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile` around lines 56 - 59, Replace the floating
wget/install steps for apache-arrow-apt-source-latest-noble.deb with a
checksum-verified flow: obtain the package SHA256 locally, add that constant to
the Dockerfile, download the file with the existing wget command, verify the
file against the SHA256 (failing the build on mismatch), and only then install
the package (using dpkg -i or apt-get install
./apache-arrow-apt-source-latest-noble.deb) and remove the file; update the
lines referencing apache-arrow-apt-source-latest-noble.deb to include the
verification step so builds are reproducible and fail fast on checksum mismatch.

Ubuntu 22.04 ships Boost 1.74 which does not support the
BOOST_PROCESS_USE_STD_FS macro, causing unresolved boost::filesystem
symbols when linking TOPP tools. Ubuntu 24.04 ships Boost 1.83 where
the macro works correctly and boost::process uses std::filesystem.

- Base and runtime images: ubuntu:22.04 → ubuntu:24.04
- Boost packages: version-pinned 1.74 → unversioned (1.83)
- Arrow APT source: jammy → noble
- Runtime Boost libs: -dev → versioned runtime (1.83.0)

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
@timosachsenberg
timosachsenberg force-pushed the test/docker-ubuntu-24.04 branch from cdd5b25 to 0060baa Compare March 26, 2026 06:32

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

♻️ Duplicate comments (1)
dockerfiles/Dockerfile (1)

56-58: ⚠️ Potential issue | 🟠 Major

Don’t mix a floating Arrow repo with fixed 2300 runtime packages.

base and library each resolve apache-arrow-apt-source-latest-noble.deb on their own, but library is pinned to libarrow2300 / libparquet2300. Since cmake/cmake_findExternalLibs.cmake:190-193 only requires Arrow/Parquet 23+, the build stage can drift to a newer Arrow release while the runtime stage stays on 2300, or the runtime install can stop resolving entirely when the repo advances. Pin one Arrow release selection and reuse it in both stages.

For Apache Arrow's Ubuntu Noble packages, does `apache-arrow-apt-source-latest-noble.deb` track the latest Arrow release, and what runtime package names are published for Arrow 23 versus newer releases (for example `libarrow2300` / `libparquet2300`)?

Also applies to: 181-185

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile` around lines 56 - 58, The Dockerfile mixes a floating
Arrow apt source (apache-arrow-apt-source-latest-noble.deb) with runtime
packages pinned to libarrow2300/libparquet2300, which can cause mismatches; fix
it by selecting and pinning a single Arrow release and reusing that pin in both
build and runtime stages (e.g., replace the
"apache-arrow-apt-source-latest-noble.deb" fetch with a specific release
artifact or introduce an ARG like ARROW_VERSION and use it to construct the
apt-source filename and the exact runtime package names), ensure both the build
stage that downloads the apt source and the runtime stage that installs
libparquet-dev/libarrow2300 reference the same ARROW_VERSION identifier so the
repository and package names remain consistent across stages.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@dockerfiles/Dockerfile`:
- Around line 181-187: After installing libarrow2300 and libparquet2300 in the
library stage, remove the Apache Arrow APT source so downstream stages don't
depend on the external repo: purge the package
apache-arrow-apt-source-latest-noble (or delete its file in
/etc/apt/sources.list.d/) immediately after the apt-get install of libarrow2300
and libparquet2300 and before running apt-get purge wget/apt-get autoremove;
reference the apache-arrow-apt-source-latest-noble .deb and the installed
packages libarrow2300 and libparquet2300 when making this change so the
tools-thirdparty and test stages no longer inherit the Arrow apt source.

---

Duplicate comments:
In `@dockerfiles/Dockerfile`:
- Around line 56-58: The Dockerfile mixes a floating Arrow apt source
(apache-arrow-apt-source-latest-noble.deb) with runtime packages pinned to
libarrow2300/libparquet2300, which can cause mismatches; fix it by selecting and
pinning a single Arrow release and reusing that pin in both build and runtime
stages (e.g., replace the "apache-arrow-apt-source-latest-noble.deb" fetch with
a specific release artifact or introduce an ARG like ARROW_VERSION and use it to
construct the apt-source filename and the exact runtime package names), ensure
both the build stage that downloads the apt source and the runtime stage that
installs libparquet-dev/libarrow2300 reference the same ARROW_VERSION identifier
so the repository and package names remain consistent across stages.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: ef7e8784-dbf0-411e-aa3e-bb350180cded

📥 Commits

Reviewing files that changed from the base of the PR and between cdd5b25 and 0060baa.

📒 Files selected for processing (1)
  • dockerfiles/Dockerfile

Comment thread dockerfiles/Dockerfile
Comment on lines +181 to +187
&& wget https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb \
&& apt-get install -y --no-install-recommends ./apache-arrow-apt-source-latest-noble.deb \
&& apt-get update && apt-get install -y --no-install-recommends --no-install-suggests \
libarrow2300 \
libparquet2300 \
&& rm apache-arrow-apt-source-latest-noble.deb \
&& apt-get purge -y wget && apt-get autoremove -y \

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Verify that `library` adds the Arrow repo and descendant stages still run `apt-get update`.
rg -n -C2 'FROM ubuntu:24\.04 AS library|apache-arrow-apt-source-latest-noble\.deb|FROM library AS tools|FROM tools AS tools-thirdparty|FROM tools-thirdparty AS test|apt-get update' dockerfiles/Dockerfile

Repository: OpenMS/OpenMS

Length of output: 2392


Remove the Arrow APT source package after installing the shared libraries.

The library stage installs the Apache Arrow APT source via the .deb package, but only removes the .deb file at line 186. The APT source configuration (typically in /etc/apt/sources.list.d/) persists into descendant stages (tools-thirdparty and test), which run apt-get update at lines 211 and 244. Purge the source package with apt-get purge -y apache-arrow-apt-source-latest-noble or manually remove its configuration file once libarrow2300 and libparquet2300 are installed, to avoid making unrelated downstream package updates dependent on an external repository.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile` around lines 181 - 187, After installing libarrow2300
and libparquet2300 in the library stage, remove the Apache Arrow APT source so
downstream stages don't depend on the external repo: purge the package
apache-arrow-apt-source-latest-noble (or delete its file in
/etc/apt/sources.list.d/) immediately after the apt-get install of libarrow2300
and libparquet2300 and before running apt-get purge wget/apt-get autoremove;
reference the apache-arrow-apt-source-latest-noble .deb and the installed
packages libarrow2300 and libparquet2300 when making this change so the
tools-thirdparty and test stages no longer inherit the Arrow apt source.

The Ubuntu 24.04 upgrade (0060baa) added Arrow/Parquet runtime
library download to the library stage but omitted ca-certificates,
causing wget to fail TLS verification on repo1.maven.org.

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

♻️ Duplicate comments (2)
dockerfiles/Dockerfile (2)

56-59: ⚠️ Potential issue | 🟠 Major

Checksum-verify the Arrow APT source in both stages.

Both installs still fetch the floating apache-arrow-apt-source-latest-noble.deb and execute it immediately. That makes the image non-reproducible and trusts an unverified external package.

Apply the same checksum gate in base and library.

Representative hardening
 FROM ubuntu:24.04 AS base
+ARG ARROW_APT_SOURCE_SHA256=<resolved-sha256>
 ...
   && wget https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb \
+  && echo "${ARROW_APT_SOURCE_SHA256}  apache-arrow-apt-source-latest-noble.deb" | sha256sum -c - \
   && apt-get install -y --no-install-recommends ./apache-arrow-apt-source-latest-noble.deb \
#!/bin/bash
set -euo pipefail

python <<'PY'
import hashlib
import urllib.request

url = "https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb"
digest = hashlib.sha256()

with urllib.request.urlopen(url) as resp:
    while True:
        chunk = resp.read(1024 * 1024)
        if not chunk:
            break
        digest.update(chunk)

print(digest.hexdigest())
PY

Also applies to: 182-183

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile` around lines 56 - 59, Replace the blind
download+install of
"https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb"
in both stages ("base" and "library") with a checksum-gated flow: add a
hardcoded expected SHA256 (computed offline) as a variable, download the .deb to
a temporary file, compute its SHA256 (e.g., with sha256sum or python -c) and
compare to the expected value, and only then run apt-get install -y
--no-install-recommends ./apache-arrow-apt-source-latest-noble.deb; fail the
build immediately if the checksum mismatches and still remove the temporary file
after install. Ensure you apply this exact change around the wget + apt-get
install ./apache-arrow-apt-source-latest-noble.deb sequence in both stages.

182-188: ⚠️ Potential issue | 🟠 Major

Purge the Arrow APT source after installing the runtime libraries.

Removing only the downloaded .deb leaves apache-arrow-apt-source-latest-noble installed, so descendant runtime stages still depend on that external repo for later apt-get update calls.

Suggested cleanup
   && apt-get update && apt-get install -y --no-install-recommends --no-install-suggests \
     libarrow2300 \
     libparquet2300 \
+  && apt-get purge -y apache-arrow-apt-source-latest-noble \
   && rm apache-arrow-apt-source-latest-noble.deb \
   && apt-get purge -y wget && apt-get autoremove -y \
#!/bin/bash
set -euo pipefail
rg -n -C2 'apache-arrow-apt-source-latest-noble|FROM tools AS tools-thirdparty|FROM tools-thirdparty AS test|apt-get update' dockerfiles/Dockerfile
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile` around lines 182 - 188, The Dockerfile currently
removes only the downloaded .deb but leaves the installed package
apache-arrow-apt-source-latest-noble, so purge that installed APT source after
installing the runtime libs to avoid leaving an external repo for descendant
stages; modify the sequence around the wget/apt-get/install/rm steps to run a
removal/purge of the apache-arrow-apt-source-latest-noble package (and follow
with autoremove/clean) after rm apache-arrow-apt-source-latest-noble.deb and
before final cleanup of wget, so the package name
apache-arrow-apt-source-latest-noble is explicitly removed from the image.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@dockerfiles/Dockerfile`:
- Line 58: The build stage installs an unversioned libparquet-dev while the
runtime stage pins libarrow2300 and libparquet2300, which can cause ABI
mismatches; change the Dockerfile to pin the Arrow package version consistently
across stages by introducing a build ARG (e.g., ARROW_VERSION) and use it when
installing libparquet-dev in the build stage and when installing libarrow2300
and libparquet2300 in the runtime stage (or alternatively capture the exact
package version installed during build and propagate it to the runtime installs)
so libparquet-dev, libarrow2300 and libparquet2300 come from the same Arrow
version.

---

Duplicate comments:
In `@dockerfiles/Dockerfile`:
- Around line 56-59: Replace the blind download+install of
"https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb"
in both stages ("base" and "library") with a checksum-gated flow: add a
hardcoded expected SHA256 (computed offline) as a variable, download the .deb to
a temporary file, compute its SHA256 (e.g., with sha256sum or python -c) and
compare to the expected value, and only then run apt-get install -y
--no-install-recommends ./apache-arrow-apt-source-latest-noble.deb; fail the
build immediately if the checksum mismatches and still remove the temporary file
after install. Ensure you apply this exact change around the wget + apt-get
install ./apache-arrow-apt-source-latest-noble.deb sequence in both stages.
- Around line 182-188: The Dockerfile currently removes only the downloaded .deb
but leaves the installed package apache-arrow-apt-source-latest-noble, so purge
that installed APT source after installing the runtime libs to avoid leaving an
external repo for descendant stages; modify the sequence around the
wget/apt-get/install/rm steps to run a removal/purge of the
apache-arrow-apt-source-latest-noble package (and follow with autoremove/clean)
after rm apache-arrow-apt-source-latest-noble.deb and before final cleanup of
wget, so the package name apache-arrow-apt-source-latest-noble is explicitly
removed from the image.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 17a4c766-f6d8-4a42-981c-90225a30765b

📥 Commits

Reviewing files that changed from the base of the PR and between 0060baa and ca5c20b.

📒 Files selected for processing (1)
  • dockerfiles/Dockerfile

Comment thread dockerfiles/Dockerfile
&& apt-get install -y --no-install-recommends ./apache-arrow-apt-source-latest-jammy.deb \
&& wget https://repo1.maven.org/maven2/org/apache/arrow/ubuntu/apache-arrow-apt-source-latest-noble.deb \
&& apt-get install -y --no-install-recommends ./apache-arrow-apt-source-latest-noble.deb \
&& apt-get update && apt-get install -y --no-install-recommends --no-install-suggests libparquet-dev \

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail
rg -n -C2 'libparquet-dev|libarrow2300|libparquet2300' dockerfiles/Dockerfile

Repository: OpenMS/OpenMS

Length of output: 782


Keep Arrow build-time and runtime packages on the same version selector.

The build stage installs unversioned libparquet-dev (line 58), which pulls the latest available version from the Apache Arrow apt-source at build time. The runtime stage pins specific versions: libarrow2300 and libparquet2300 (lines 184-186). If the Arrow apt-source updates, the build stage could compile against different library headers than the runtime uses, causing potential ABI mismatches.

Pin both stages to the same Arrow version, or derive the runtime package versions from the exact Arrow version installed during the build stage.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@dockerfiles/Dockerfile` at line 58, The build stage installs an unversioned
libparquet-dev while the runtime stage pins libarrow2300 and libparquet2300,
which can cause ABI mismatches; change the Dockerfile to pin the Arrow package
version consistently across stages by introducing a build ARG (e.g.,
ARROW_VERSION) and use it when installing libparquet-dev in the build stage and
when installing libarrow2300 and libparquet2300 in the runtime stage (or
alternatively capture the exact package version installed during build and
propagate it to the runtime installs) so libparquet-dev, libarrow2300 and
libparquet2300 come from the same Arrow version.

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.

1 participant