From 4aceceb5d4d040556d13051cd5cffef9f90c3f66 Mon Sep 17 00:00:00 2001 From: Aaron Murray Date: Mon, 8 Mar 2021 06:30:32 -0600 Subject: [PATCH] skip reboot if error applying network config --- install | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/install b/install index 95d5a88..89bca6f 100755 --- a/install +++ b/install @@ -13,7 +13,7 @@ # https://github.com/armbian/config/blob/master/debian-software # https://forum.openmediavault.org/index.php/Thread/25062-Install-OMV5-on-Debian-10-Buster/ # -# version: 1.3.1 +# version: 1.3.2 # if [[ $(id -u) -ne 0 ]]; then @@ -533,7 +533,10 @@ if [ ${version} -gt 4 ] && [ ${skipNet} -ne 1 ]; then echo "IP address may change and you could lose connection if running this script via ssh." # create config files - ${confCmd} ${network} + if ! ${confCmd} ${network}; then + echo "Error applying network changes. Skipping reboot!" + skipReboot=1 + fi if [ ${skipReboot} -ne 1 ]; then echo "Network setup. Rebooting..."