diff --git a/scripts/install b/scripts/install index b0fe780..444173d 100644 --- a/scripts/install +++ b/scripts/install @@ -99,10 +99,10 @@ ynh_psql_setup_db --db_user=$db_name --db_name=$db_name # Créer le dossier de log mkdir -p /var/log/$app touch /var/log/$app/$app.log -install_log=/var/log/$app/installation.log -touch $install_log +#install_log=/var/log/$app/installation.log +#touch $install_log chown $app -R /var/log/$app -chown admin -R $install_log +#chown admin -R $install_log # Configuration de logrotate ynh_use_logrotate @@ -135,7 +135,8 @@ setup="{ }" pushd $final_path - ynh_exec_as $app $ynh_node_load_PATH $final_path/nodebb setup "${setup}" | tee -a $install_log 2>/dev/null + ynh_use_nodejs + ynh_exec_as $app env $ynh_node_load_PATH $final_path/nodebb setup "${setup}" 2>/dev/null popd chmod 400 "$final_path/config.json" diff --git a/scripts/upgrade b/scripts/upgrade index 9e239ce..2128358 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -84,8 +84,9 @@ then ynh_script_progression --message="Upgrading source files..." --weight=1 pushd $final_path + ynh_use_nodejs # Shut down your forum - ynh_exec_as $app $ynh_node_load_PATH $final_path/nodebb stop + ynh_exec_as $app env "$ynh_node_load_PATH" $final_path/nodebb stop # Grab the latest and greatest code git fetch # Grab the latest code from the NodeBB Repository git reset --hard origin/$nodebb_version # Replace v1.12.x with the branch name!