Skip to content

installer: support BusyBox cp - #16537

Merged
xokdvium merged 2 commits into
NixOS:masterfrom
fgaz:installer-busybox
Sep 28, 2026
Merged

xokdvium merged 2 commits into
NixOS:masterfrom
fgaz:installer-busybox

Conversation

@fgaz

@fgaz fgaz commented Sep 28, 2026 •

Copy link
Copy Markdown
Member

Motivation

Fixes #13480

Context


Add 👍 to pull requests you find important.

The Nix maintainer team uses a GitHub project board to schedule and track reviews.

@fgaz
fgaz requested a review from edolstra as a code owner September 28, 2026 12:33
@fgaz
fgaz force-pushed the installer-busybox branch from ed15611 to c185669 Compare September 28, 2026 12:38
@fgaz fgaz changed the title installer: support BusyBox cp in single-user mode installer: support BusyBox cp Sep 28, 2026
@xokdvium

Copy link
Copy Markdown
Contributor

Could you try adding a test for alpine images? https://github.com/NixOS/nix/blob/master/tests/installer/default.nix

@fgaz
fgaz force-pushed the installer-busybox branch 2 times, most recently from 91df610 to 9e4445e Compare September 28, 2026 13:06
Comment thread tests/installer/default.nix Outdated
Comment thread tests/installer/default.nix Outdated
@fgaz
fgaz force-pushed the installer-busybox branch from 9e4445e to 2070b62 Compare September 28, 2026 13:12
xokdvium and others added 2 commits September 28, 2026 19:29
This uncovers a latent bug in the tests: `MAYBESUDO: unbound variable` dating
back to 717e81d. `sudo` was never actually needed
and root's channel was never modified because the undefined variable was expanded on
the host and not the VM under test.

Keeping the test's behavior the same, we can safely remove the entire MAYBESUDO
machinery without functional changes.
Fixes NixOS#13480

Multi-user installs on alpine are not yet supported and thus aren't modified.
Also it seems tricky to reliably figure out which `cp` binary would be used
by `root`.

Co-authored-by: Sergei Zimmerman <sergei@zimmerman.foo>
@lisanna-dettwyler
lisanna-dettwyler added this pull request to the merge queue Sep 28, 2026
@xokdvium
xokdvium removed this pull request from the merge queue due to a manual request Sep 28, 2026
@xokdvium
xokdvium added this pull request to the merge queue Sep 28, 2026
Merged via the queue into NixOS:master with commit 9bc9ab3 Sep 28, 2026
32 of 41 checks passed
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.

installers: busybox cp in Alpine fails due to unsupported --preserve flags

3 participants