mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-25 16:33:15 +00:00
dockerTools.binSh: init
This commit is contained in:
parent
f7ee2706c2
commit
e054694925
@ -1,4 +1,5 @@
|
||||
{
|
||||
bashInteractive,
|
||||
buildPackages,
|
||||
cacert,
|
||||
callPackage,
|
||||
@ -688,6 +689,7 @@ rec {
|
||||
# Provide a /etc/passwd and /etc/group that contain root and nobody.
|
||||
# Useful when packaging binaries that insist on using nss to look up
|
||||
# username/groups (like nginx).
|
||||
# /bin/sh is fine to not exist, and provided by another shim.
|
||||
fakeNss = symlinkJoin {
|
||||
name = "fake-nss";
|
||||
paths = [
|
||||
@ -705,6 +707,12 @@ rec {
|
||||
];
|
||||
};
|
||||
|
||||
# This provides /bin/sh, pointing to bashInteractive.
|
||||
binSh = runCommand "bin-sh" {} ''
|
||||
mkdir -p $out/bin
|
||||
ln -s ${bashInteractive}/bin/bash $out/bin/sh
|
||||
'';
|
||||
|
||||
# Build an image and populate its nix database with the provided
|
||||
# contents. The main purpose is to be able to use nix commands in
|
||||
# the container.
|
||||
|
Loading…
Reference in New Issue
Block a user