mirror of
https://github.com/numtide/nixos-anywhere.git
synced 2024-10-04 08:27:30 +03:00
use early return in runKexec
This commit is contained in:
parent
ef708ac46d
commit
bc77bd1cca
@ -375,7 +375,10 @@ importFacts() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
runKexec() {
|
runKexec() {
|
||||||
if [[ ${isKexec-n} == "n" ]] && [[ ${isInstaller-n} == "n" ]]; then
|
if [[ ${isKexec-n} == "y" ]] || [[ ${isInstaller-n} == "y" ]]; then
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ ${isContainer-none} != "none" ]]; then
|
if [[ ${isContainer-none} != "none" ]]; then
|
||||||
echo "WARNING: This script does not support running from a '${isContainer}' container. kexec will likely not work" >&2
|
echo "WARNING: This script does not support running from a '${isContainer}' container. kexec will likely not work" >&2
|
||||||
fi
|
fi
|
||||||
@ -433,7 +436,6 @@ SSH
|
|||||||
|
|
||||||
# waiting for machine to become available again
|
# waiting for machine to become available again
|
||||||
until runSsh -o ConnectTimeout=10 -- exit 0; do sleep 5; done
|
until runSsh -o ConnectTimeout=10 -- exit 0; do sleep 5; done
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
runDisko() {
|
runDisko() {
|
||||||
|
Loading…
Reference in New Issue
Block a user