Skip to content
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

singularity-tools: create required bind points #44075

Closed
wants to merge 2 commits into from

Conversation

jbedo
Copy link
Contributor

@jbedo jbedo commented Jul 25, 2018

Motivation for this change

Latest version of singularity requires the creation of /root and two bind points in /etc/.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Fits CONTRIBUTING.md.

@Mic92
Copy link
Member

Mic92 commented Aug 3, 2018

I am not familiar with this code. Do you have an example I can test?

@jbedo
Copy link
Contributor Author

jbedo commented Aug 5, 2018

Sure, see this https://gist.github.com/jbedo/c32f6bb93470dc849e4d723c5cda7118. Then try dropping into a shell using singularity after building:

# sudo singularity shell result
WARNING: Non existent bind point (file) in container: '/etc/localtime'
WARNING: Non existent bind point (file) in container: '/etc/hosts'
ERROR  : Base home directory does not exist within the container: /root
ABORT  : Retval = 255

BTW, is there any way to tag this code with me as the maintainer? Since I wrote it and am maintaining it, would be nice to do so for clarity.

@Mic92
Copy link
Member

Mic92 commented Aug 6, 2018

You should be able to set meta the same way as in stdenv.mkDerivation:

nix-repl> (runCommand "foo" { meta.maintainers = ["foo"]; } "echo test > $out" ).meta.maintainers
[ "foo" ]

Copy link
Member

@Mic92 Mic92 left a comment

Choose a reason for hiding this comment

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

Changes work.

@Mic92
Copy link
Member

Mic92 commented Nov 23, 2018

Was this closed intentionally?

@jbedo
Copy link
Contributor Author

jbedo commented Nov 23, 2018

Sorry I got a bit confused; it's part of the new pull request #50939.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants