From 8e303e642539b8d0479540cfe81f397649365c6f Mon Sep 17 00:00:00 2001 From: Dennis ten Hoove Date: Mon, 5 Aug 2024 23:14:02 +0200 Subject: [PATCH] [arkdep] Do not error on failed bootctl set-default Buggy firmware or otherwise flawed firmware implementations may fail to perform this step. Having it completely discard the deployment because of it would fully break Arkdep on affected systems. --- arkdep | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arkdep b/arkdep index fa915a8..157dac1 100755 --- a/arkdep +++ b/arkdep @@ -824,7 +824,7 @@ deploy () { # Lets ensure the latest deployment is active, even if it is already deployed if [[ latest_image_always_default -eq 1 ]] && [[ ! $ARKDEP_NO_BOOTCTL -eq 1 ]]; then # Allow it to error, it is no big deal if it does - bootctl set-default ${data[0]}.conf || printf '\e[1;33m\e[0m\e[1m Failed to set default bootloader entry on latest_image_always_default\e[0m\n' + bootctl set-default ${data[0]}.conf || printf '\e[1;33m\e[0m\e[1m Failed to set default bootloader entry, this might be a firmware bug\e[0m\n' fi printf "\e[1;33m\e[0m\e[1m ${data[0]} is already deployed, canceling deployment\e[0m\n" @@ -1119,7 +1119,7 @@ deploy () { printf '\e[1;34m-->\e[0m\e[1m Setting new bootloader entry as default\e[0m\n' # Do not set default boot entry if ARKDEP_NO_BOOTCTL is set if [[ ! $ARKDEP_NO_BOOTCTL -eq 1 ]]; then - bootctl set-default ${data[0]}.conf || cleanup_and_quit "Failed to set default bootloader entry" + bootctl set-default ${data[0]}.conf || printf '\e[1;33m\e[0m\e[1m Failed to set default bootloader entry, this might be a firmware bug\e[0m\n' else printf '\e[1;33m\e[0m\e[1m Not running bootctl set-default because overwritten with ARKDEP_NO_BOOTCTL\e[0m\n' fi