diff --git a/check_process b/check_process index 759a0c8..3e6fc80 100644 --- a/check_process +++ b/check_process @@ -1,12 +1,12 @@ ;; Test complet ; Manifest - domain="domain.tld" (DOMAIN) - path="/path" (PATH) - admin="john" (USER) + domain="domain.tld" + path="/path" + admin="john" language="fr" - is_public=1 (PUBLIC|public=1|private=0) + is_public=1 password="pass" - port="666" (PORT) + port="666" ; Checks pkg_linter=1 setup_sub_dir=1 diff --git a/manifest.json b/manifest.json index aed4366..eafe5a8 100644 --- a/manifest.json +++ b/manifest.json @@ -15,7 +15,7 @@ "url": "https://github.com/Yunohost-Apps/nodebb_ynh" }, "requirements": { - "yunohost": ">> 4.1.7" + "yunohost": ">> 4.2.4" }, "multi_instance": false, "services": [ diff --git a/scripts/_common.sh b/scripts/_common.sh index 1382e95..c11637d 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -21,20 +21,6 @@ nodejs_version=14 # FUTURE OFFICIAL HELPERS #================================================= -# Execute a command as another user -# usage: ynh_exec_as USER COMMAND [ARG ...] -ynh_exec_as() { - local USER=$1 - shift 1 - - if [[ $USER = $(whoami) ]]; then - eval "$@" - else - sudo -u "$USER" "$@" - fi -} - - # Send an email to inform the administrator # # usage: ynh_send_readme_to_admin app_message [recipients] diff --git a/scripts/install b/scripts/install index 39cf80a..bf7ef7c 100644 --- a/scripts/install +++ b/scripts/install @@ -111,6 +111,10 @@ ynh_app_setting_set --app=$app --key=final_path --value=$final_path # Download, check integrity, uncompress and patch the source from app.src ynh_setup_source --dest_dir="$final_path" +chmod 750 "$final_path" +chmod -R o-rwx "$final_path" +chown -R $app:www-data "$final_path" + #================================================= # NGINX CONFIGURATION #================================================= @@ -148,9 +152,9 @@ pushd $final_path #npm install nodebb-plugin-dbsearch --save-prod #ynh_exec_as $app env $ynh_node_load_PATH #./nodebb build -l - #exec_as $app ./nodebb setup -l > $install_log - #exec_as $app npm install nodebb-plugin-dbsearch --save-prod - #exec_as $app ./nodebb build -l + #ynh_exec_as $app ./nodebb setup -l > $install_log + #ynh_exec_as $app npm install nodebb-plugin-dbsearch --save-prod + #ynh_exec_as $app ./nodebb build -l popd #================================================= @@ -207,10 +211,10 @@ $mail_content If you are facing any problem or want to improve this app, please open a new issue here: https://github.com/YunoHost-Apps/nodebb_ynh" +ynh_send_readme_to_admin "$message" + #================================================= # END OF SCRIPT #================================================= ynh_script_progression --message="Installation of $app completed" --last - -ynh_send_readme_to_admin "$message"