mirror of
https://github.com/nix-community/nixos-anywhere.git
synced 2024-10-05 20:27:20 +03:00
fix(src/nixos-anywhere): extra-files expects a path
This commit is contained in:
parent
d8b8cc69b0
commit
5770dd84d2
@ -33,8 +33,9 @@ Options:
|
|||||||
copy over existing /etc/ssh/ssh_host_* host keys to the installation
|
copy over existing /etc/ssh/ssh_host_* host keys to the installation
|
||||||
* --stop-after-disko
|
* --stop-after-disko
|
||||||
exit after disko formatting, you can then proceed to install manually or some other way
|
exit after disko formatting, you can then proceed to install manually or some other way
|
||||||
* --extra-files <file...>
|
* --extra-files <path>
|
||||||
files to copy into the new nixos installation
|
path to a directory to copy into the root of the new nixos installation.
|
||||||
|
Copied files will be owned by root.
|
||||||
* --disk-encryption-keys <remote_path> <local_path>
|
* --disk-encryption-keys <remote_path> <local_path>
|
||||||
copy the contents of the file or pipe in local_path to remote_path in the installer environment,
|
copy the contents of the file or pipe in local_path to remote_path in the installer environment,
|
||||||
after kexec but before installation. Can be repeated.
|
after kexec but before installation. Can be repeated.
|
||||||
@ -475,9 +476,6 @@ elif [[ ${build_on_remote-n} == "y" ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -n ${extra_files-} ]]; then
|
if [[ -n ${extra_files-} ]]; then
|
||||||
if [[ -d $extra_files ]]; then
|
|
||||||
extra_files="$extra_files/"
|
|
||||||
fi
|
|
||||||
step Copying extra files
|
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-"
|
||||||
ssh_ "chmod 755 /mnt" # tar also changes permissions of /mnt
|
ssh_ "chmod 755 /mnt" # tar also changes permissions of /mnt
|
||||||
|
Loading…
Reference in New Issue
Block a user