From 86bea30a811bd8c1a334d76d503b61da8568be30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Fri, 17 May 2024 23:52:48 +0200 Subject: [PATCH] Fix corepack install --- scripts/install | 3 ++- scripts/restore | 2 ++ scripts/upgrade | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/install b/scripts/install index 71dff90..feb3521 100644 --- a/scripts/install +++ b/scripts/install @@ -130,7 +130,8 @@ pushd "$install_dir/live" # Building assets ynh_use_nodejs corepack enable - yarn install + # This export might be removed in yunohost 12 + COREPACK_ENABLE_DOWNLOAD_PROMPT=0 yarn install echo "SAFETY_ASSURED=1">> "$config" ynh_exec_warn_less ynh_exec_as "$app" RAILS_ENV=production "$ynh_ruby_load_path" "$ld_preload" bin/bundle exec rails db:migrate --quiet ynh_exec_warn_less ynh_exec_as "$app" RAILS_ENV=production "$ynh_ruby_load_path" "$ld_preload" bin/bundle exec rails assets:precompile --quiet diff --git a/scripts/restore b/scripts/restore index 91b2c97..2fe6f1d 100644 --- a/scripts/restore +++ b/scripts/restore @@ -66,6 +66,8 @@ pushd "$install_dir/live" ynh_exec_as "$app" "$ynh_ruby_load_path" "$ld_preload" bin/bundle install --redownload -j"$(nproc)" ynh_use_nodejs + # This export might be removed in yunohost 12 + export COREPACK_ENABLE_DOWNLOAD_PROMPT=0 corepack enable yarn install popd diff --git a/scripts/upgrade b/scripts/upgrade index e16e80c..6840ba9 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -103,6 +103,8 @@ pushd "$install_dir/live" ynh_exec_as "$app" "$ynh_ruby_load_path" "$ld_preload" bin/bundle config set force_ruby_platform true --quiet ynh_exec_as "$app" "$ynh_ruby_load_path" "$ld_preload" bin/bundle install -j$(getconf _NPROCESSORS_ONLN) ynh_use_nodejs + # This export might be removed in yunohost 12 + export COREPACK_ENABLE_DOWNLOAD_PROMPT=0 corepack enable yarn install if [ -d "$install_dir/live/public/assets" ]; then