-
-
Notifications
You must be signed in to change notification settings - Fork 14.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
apptainer, singularity: precede system-level bin paths in defaultPath
and fix singularity
image running
#306730
Conversation
a1e1fc8
to
5ffacad
Compare
5ffacad
to
80ec474
Compare
80ec474
to
59d1cb1
Compare
There is no branch of yet. So if you get your pull request finished up soon, just merging it, will also make it available in the upcoming release. If not, we can still backport it, if the current approach is unusable without this change anyway. |
defaultPath
and fix singularity
image runningdefaultPath
and fix singularity
image running
defaultPath
and fix singularity
image runningdefaultPath
and fix singularity
image running
59d1cb1
to
52330bc
Compare
Prefix the upstream-given defalutPath value over the one constructed by defaultPathInputs. Make SUID'ed binaries searchable out-of-the-box non-NixOS platforms.
52330bc
to
33a00ae
Compare
Use systemBinPaths as the new way to specify system bin paths, especifally for SUID'ed binaries. Deprecate arguments setuidmapPath and setgidmapPath in favour of systemBinPaths. Add NixOS configuration option programs.singularity.systemBinPath, with "/run/wrappers/bin" included by default.
Add a Nixpkgs 24.05 release note entry explaining the introduction of `systemBinPaths` argument, the prioritization of the original (FHS) `defaultPath` values, and the deprecation of arguments `newuidmapPath`, `newgidmapPath` and NixOS configuration option `programs.singularity.enableFakeroot`.
Warn when arguments newuidmapPath and newgidmapPath is used.
33a00ae
to
c3026ac
Compare
I rebased this PR on top of I don't know how to test those GPG-related functionality. @SomeoneSerge @FynnFreyer, could you help test if the GPU works with these changes applied? BTW, should we rename |
@SomeoneSerge, could you help look at this PR? This will fix the issues regarding third-party utility access for Apptainer and SingularityCE. |
I am terribly, terribly sorry about losing touch on this one. I remember I had tried building the gpu tests just via the flake reference and I couldn't because the cuda image blew up in size. I'll give it another try |
Ok, with #323056 in I can finally run the test without modifying the
|
I think this is backport-able, but I'll look into this some more |
Backport failed for Please cherry-pick the changes locally and resolve any conflicts. git fetch origin release-24.05
git worktree add -d .worktree/backport-306730-to-release-24.05 origin/release-24.05
cd .worktree/backport-306730-to-release-24.05
git switch --create backport-306730-to-release-24.05
git cherry-pick -x 409cbbe61a551410d109b739a5cb0959a2c8db16 f6d9b4b6fc7f376e5f5ecacace951f57c155045c dbcf7cf697c601fc92da45453290b81587b87ef5 c3026ac986b6b21409a0240dcad4a411dad0d419 |
Thank you again @ShamrockLee |
#306716 needs to be backported first so that we could backport this one. |
Successfully created backport PR for |
Description of changes
apptainer
andsingularity
now prioritizePATH
from the system over those constructed from dependent packages, when it comes to the substitution ofdefaultPath
values (thePATH
hard-coded inside Apptainer/Singularity library for them to find third-party utilities). It is now constructed by the following sources, ordered by their precedence:systemBinPaths
, a new argument introduced to specify the/**/bin
paths from the system, especially those with their SUID bit set.defaultPath
value, making it work out of the box in FHS systems.defaultPathInputs
, a list of packages to form the fall-backPATH
.This change is required to enable Sylabs SingularityCE (
singularity
) to run images, as it requires afusermount3
commant with SUID bit set.The arguments
newuidmapPath
andnewgidmapPath
is deprecated in favour ofsystemBinPaths
. Their support will be removed in future releases.New option
programs.singularity.systemBinPaths
is introduced to specify thesystemBinPaths
argument of the overridden package. It includes"/run/wrappers/bin"
even if specified empty.The option
programs.singularity.enableFakeroot
is deprecated and has no effect.--fakeroot
support is now always enabled as long asprograms.singularity.systemBinPaths
is not forcefully overridden.This PR depends on #306656 and #306716, and currently contains their commits. The size of this PR will reduce once the dependent PRs are merged.
Together with #306716, this PR fixes #295809 and prevents the broken
singularity
from going into the stable release. If this fails to merge before the branch-off, I would like to have the changes backported without the deprecation warnings.Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.