From 806e6d4b181a08284093a68763878a53c2141e8e Mon Sep 17 00:00:00 2001 From: tituspijean Date: Sun, 12 Dec 2021 17:59:22 +0100 Subject: [PATCH] ynh_detect_arch is now deprecated --- scripts/upgrade | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 5c0a2e5..ff6d92e 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -71,14 +71,13 @@ then fi # Downgrade linux-image-$arch if updated to the buster-backports version -arch=$(ynh_detect_arch) -linuximage_version=$(ynh_package_version --package=linux-image-$arch) +linuximage_version=$(ynh_package_version --package=linux-image-$architecture) if [[ $linuximage_version == *"bpo10"* ]] then # Downgrading using ynh_package_install apt command without "--no-remove" and with "--allow-downgrades" # It will remove wireguard-ynh-deps and wireguard but they will be reinstalled throught upgrade process ynh_apt --allow-downgrades --option Dpkg::Options::=--force-confdef \ - --option Dpkg::Options::=--force-confold install linux-image-$arch/stable + --option Dpkg::Options::=--force-confold install linux-image-$architecture/stable #Remove backports kernel if running on it and send a mail to the admin to ask him to reboot linuxkernel_version=$(uname -r)