mirror of
https://github.com/nix-community/nixos-anywhere.git
synced 2024-08-16 03:40:36 +03:00
Merge pull request #160 from numtide/zfs-optional
skip zpool command if we don't have it installed
This commit is contained in:
commit
11d3803cc6
@ -423,7 +423,9 @@ export PATH=\$PATH:/run/current-system/sw/bin
|
|||||||
mkdir -p /mnt/tmp
|
mkdir -p /mnt/tmp
|
||||||
chmod 777 /mnt/tmp
|
chmod 777 /mnt/tmp
|
||||||
nixos-install --no-root-passwd --no-channel-copy --system "$nixos_system"
|
nixos-install --no-root-passwd --no-channel-copy --system "$nixos_system"
|
||||||
zpool export -a || : # we always want to export the zfs pools so people can boot from it without force import
|
if command -v zpool >/dev/null; then
|
||||||
|
zpool export -a || : # we always want to export the zfs pools so people can boot from it without force import
|
||||||
|
fi
|
||||||
# We will reboot in background so we can cleanly finish the script before the hosts go down.
|
# We will reboot in background so we can cleanly finish the script before the hosts go down.
|
||||||
# This makes integration into scripts easier
|
# This makes integration into scripts easier
|
||||||
nohup bash -c '${maybe_reboot}' >/dev/null &
|
nohup bash -c '${maybe_reboot}' >/dev/null &
|
||||||
|
Loading…
Reference in New Issue
Block a user