From 8b7c2045d2a87c7eb389a17fe0fe05f037e294dc Mon Sep 17 00:00:00 2001 From: Tio <38043315+tio-trom@users.noreply.github.com> Date: Mon, 25 Sep 2023 15:36:40 +0200 Subject: [PATCH] Print warning instead of killing the process It is better to print a warning than entirely killing the process --- scripts/_common.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 5332d6c..53b54d6 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -51,11 +51,11 @@ is_memory_available() { # terminates installation if requirements not met check_memory_requirements() { if ! is_swap_present ; then - ynh_die --message="You must have a swap partition in order to install and use this application" + ynh_print_warn --message="You must have a swap partition in order to install and use this application" elif ! is_swappiness_sufficient ; then - ynh_die --message="Your swappiness must be higher than 10; please see https://en.wikipedia.org/wiki/Swappiness" + ynh_print_warn --message="Your swappiness must be higher than 10; please see https://en.wikipedia.org/wiki/Swappiness" elif ! is_memory_available 1000000 ; then - ynh_die --message="You must have a minimum of 1Gb available memory (RAM+swap) for the installation" + ynh_print_warn --message="You must have a minimum of 1Gb available memory (RAM+swap) for the installation" fi } # Checks discourse upgrade memory requirements