From 3c73c3c31d4eeed7f7d198c76f99e4c4418e8cec Mon Sep 17 00:00:00 2001 From: Neko Nekowazarashi Date: Mon, 29 May 2023 18:52:52 +0700 Subject: [PATCH] perbaiki nodejs --- scripts/_common.sh | 2 ++ scripts/change_url | 4 ++-- scripts/install | 5 +++-- scripts/upgrade | 4 ++-- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 944a65e..cde0f5e 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -4,6 +4,8 @@ # COMMON VARIABLES #================================================= +nodejs_version=18.16.0 + #================================================= # PERSONAL HELPERS #================================================= diff --git a/scripts/change_url b/scripts/change_url index 134f446..00732ee 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -42,9 +42,9 @@ fi ynh_script_progression --message="Rebuilding the app..." --weight=1 ynh_use_nodejs -ynh_exec_as $app $ynh_npm install +ynh_exec_warn_less ynh_exec_as $app $ynh_node_load_PATH $ynh_npm install npx next telemetry disable -ynh_exec_as $app $ynh_npm build +ynh_exec_warn_less ynh_exec_as $app $ynh_node_load_PATH $ynh_npm build #================================================= # GENERIC FINALISATION diff --git a/scripts/install b/scripts/install index 587981d..7ec68ab 100755 --- a/scripts/install +++ b/scripts/install @@ -55,10 +55,11 @@ chown $app:$app "$install_dir/.env.local" #================================================= ynh_script_progression --message="Building the app..." --weight=1 +ynh_install_nodejs --nodejs_version=18.16.0 ynh_use_nodejs -ynh_exec_as $app $ynh_npm install +ynh_exec_warn_less ynh_exec_as $app $ynh_node_load_PATH $ynh_npm install npx next telemetry disable -ynh_exec_as $app $ynh_npm build +ynh_exec_warn_less ynh_exec_as $app $ynh_node_load_PATH $ynh_npm build #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index 974fffd..bef01fb 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -117,9 +117,9 @@ chown $app:$app "$install_dir/.env.local" ynh_script_progression --message="Rebuilding the app..." --weight=1 ynh_use_nodejs -ynh_exec_as $app $ynh_npm install +ynh_exec_warn_less ynh_exec_as $app $ynh_node_load_PATH $ynh_npm install npx next telemetry disable -ynh_exec_as $app $ynh_npm build +ynh_exec_warn_less ynh_exec_as $app $ynh_node_load_PATH $ynh_npm build #================================================= # START SYSTEMD SERVICE