From 096e3cbdec300579ad6f46f056e1dc5427617a35 Mon Sep 17 00:00:00 2001 From: Alex Biehl Date: Wed, 27 Mar 2019 11:34:35 +0100 Subject: [PATCH] Add /nix/store to each layer.tar To be totally consistent with the way Docker builds images we need to include the /nix/store in the layer tarballs first. --- pkgs/build-support/docker/store-path-to-layer.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/build-support/docker/store-path-to-layer.sh b/pkgs/build-support/docker/store-path-to-layer.sh index ff814c1f613..4cf338b9b25 100755 --- a/pkgs/build-support/docker/store-path-to-layer.sh +++ b/pkgs/build-support/docker/store-path-to-layer.sh @@ -9,6 +9,7 @@ layerPath="./layers/$layerNumber" echo "Creating layer #$layerNumber for $@" mkdir -p "$layerPath" +tar --no-recursion -rf "$layerPath/layer.tar" /nix /nix/store tar -rpf "$layerPath/layer.tar" --hard-dereference --sort=name \ --mtime="@$SOURCE_DATE_EPOCH" \ --owner=0 --group=0 "$@"