Merge pull request #40947 from samueldr/fix/34779
dockerTools: fixes extraCommands for mkRootLayer.
This commit is contained in:
@@ -352,7 +352,9 @@ rec {
|
||||
extraCommands ? ""
|
||||
}:
|
||||
# Generate an executable script from the `runAsRoot` text.
|
||||
let runAsRootScript = shellScript "run-as-root.sh" runAsRoot;
|
||||
let
|
||||
runAsRootScript = shellScript "run-as-root.sh" runAsRoot;
|
||||
extraCommandsScript = shellScript "extra-commands.sh" extraCommands;
|
||||
in runWithOverlay {
|
||||
name = "docker-layer-${name}";
|
||||
|
||||
@@ -390,7 +392,7 @@ rec {
|
||||
'';
|
||||
|
||||
postUmount = ''
|
||||
(cd layer; eval "${extraCommands}")
|
||||
(cd layer; ${extraCommandsScript})
|
||||
|
||||
echo "Packing layer..."
|
||||
mkdir $out
|
||||
|
||||
Reference in New Issue
Block a user