about summary refs log tree commit diff
diff options
context:
space:
mode:
authorVincent Ambo <tazjin@google.com>2019-09-21T14·03+0100
committerVincent Ambo <github@tazj.in>2019-09-21T14·25+0100
commitc391a7b7f81f30de59b3bf186bf0e51ad0e308ce (patch)
treee15068a5da48130762bd2bf7b658b1c05d521c2d
parentda6fd1d79e03795e0432553c1875774a61267826 (diff)
fix(build-image): Use absolute paths in tarballs
-rw-r--r--tools/nixery/build-image/build-image.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/nixery/build-image/build-image.nix b/tools/nixery/build-image/build-image.nix
index 8f54f53261b2..9cfb806e47b1 100644
--- a/tools/nixery/build-image/build-image.nix
+++ b/tools/nixery/build-image/build-image.nix
@@ -133,11 +133,11 @@ let
   # their contents.
   pathsToLayer = paths: runCommand "layer.tar" {
   } ''
-    tar --no-recursion -rf "$out" \
+    tar --no-recursion -Prf "$out" \
         --mtime="@$SOURCE_DATE_EPOCH" \
         --owner=0 --group=0 /nix /nix/store
 
-    tar -rpf "$out" --hard-dereference --sort=name \
+    tar -Prpf "$out" --hard-dereference --sort=name \
         --mtime="@$SOURCE_DATE_EPOCH" \
         --owner=0 --group=0 ${lib.concatStringsSep " " paths}
   '';