fix(src/nixos-anywhere): make root own copied files

This commit is contained in:
Sizhe Zhao 2024-05-27 10:43:10 +08:00
parent 5770dd84d2
commit 09f1f8306b
No known key found for this signature in database
GPG Key ID: 52091D14C4D7017B

View File

@ -477,7 +477,7 @@ fi
if [[ -n ${extra_files-} ]]; then
step Copying extra files
tar -C "$extra_files" -cpf- . | ssh_ "${maybe_sudo} tar -C /mnt -xf-"
tar -C "$extra_files" -cpf- . | ssh_ "${maybe_sudo} tar -C /mnt -xf- --no-same-owner"
ssh_ "chmod 755 /mnt" # tar also changes permissions of /mnt
fi