docs(debian): annotate apt package roles in base image - #374
Open
wdconinc wants to merge 2 commits into
Open
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR improves the readability/maintainability of the Debian base image by documenting the role of each apt-installed package (OS setup vs Spack prerequisite vs intentional system external), while keeping the installed package set the same.
Changes:
- Replace long
apt-get installline continuations with a commented package-list heredoc, filtered throughsedand fed toapt-getviaxargs. - Add short inline rationales for each apt package in both the “base tools” and “Spack runtime deps” apt blocks.
Comments suppressed due to low confidence (1)
containers/debian/Dockerfile:160
- Using
xargs -rhere can hide mistakes by turning an empty package list into a no-op (the build would succeed but Spack runtime deps wouldn’t be installed). Consider dropping-rso the build fails fast if the list is accidentally empty.
sed -e 's/[[:space:]]*#.*$//' -e '/^[[:space:]]*$/d' <<'EOF_APT_PACKAGES' \
| xargs -r apt-get -yqq install --no-install-recommends
wdconinc
commented
Jul 31, 2026
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Co-authored-by: Wouter Deconinck <wdconinc@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This documents why the Debian base image installs these packages with apt instead of leaving the question to Spack-managed environments. Reviewers should be able to see which packages are OS setup, Spack prerequisites, or deliberate system externals at a glance.
The Dockerfile now feeds the apt package lists through a commented heredoc using
sedandxargs, so each package can carry an inline justification without changing the installed package set. The same pattern is used for the base tools block and the Spack runtime dependency block.Notable details:
Validation:
docker buildx build -f containers/debian/Dockerfile containers/debian