1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/snserver_ynh.git synced 2024-09-03 20:26:22 +02:00

Fix: increase swap & add node_option --max-old-space-size

This commit is contained in:
Fabian Wilkens 2022-08-10 16:49:52 +02:00
parent 353c35f573
commit bd0fea248a
No known key found for this signature in database
GPG key ID: 23DFA025BB4E9FAB
3 changed files with 6 additions and 10 deletions

View file

@ -5,8 +5,8 @@
#================================================= #=================================================
NODEJS_VERSION="16" NODEJS_VERSION="16"
swap_needed=2048 swap_needed=4096
node_max_old_space_size=6144 node_max_old_space_size=4096
# dependencies used by the app # dependencies used by the app
pkg_dependencies="" pkg_dependencies=""

View file

@ -198,10 +198,8 @@ ynh_script_progression --message="Installing Standard Notes - Syncing Server..."
ynh_use_nodejs ynh_use_nodejs
pushd "$final_path/live" pushd "$final_path/live"
#ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn install --pure-lockfile ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn install --immutable
#ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn build ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn build
ynh_exec_warn_less ynh_exec_as $app PATH=$ynh_node_load_PATH yarn install --immutable
ynh_exec_warn_less ynh_exec_as $app PATH=$ynh_node_load_PATH yarn build
popd popd
#================================================= #=================================================

View file

@ -343,10 +343,8 @@ then
ynh_script_progression --message="Installing Standard Notes - Syncing Server..." --weight=93 ynh_script_progression --message="Installing Standard Notes - Syncing Server..." --weight=93
ynh_use_nodejs ynh_use_nodejs
pushd "$final_path/live" pushd "$final_path/live"
#ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn install --pure-lockfile ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn install --immutable
#ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn build ynh_exec_warn_less ynh_exec_as $app env NODE_OPTIONS="--max-old-space-size=$node_max_old_space_size" PATH=$ynh_node_load_PATH yarn build
ynh_exec_warn_less ynh_exec_as $app PATH=$ynh_node_load_PATH yarn install --immutable
ynh_exec_warn_less ynh_exec_as $app PATH=$ynh_node_load_PATH yarn build
popd popd
fi fi