From c084c6241ea565685d9db82d4bf7aa8749388b40 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sat, 9 Sep 2023 08:53:24 +0200 Subject: [PATCH 1/7] Update manifest.toml --- manifest.toml | 2 -- 1 file changed, 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index 2b096cd..e993df1 100644 --- a/manifest.toml +++ b/manifest.toml @@ -35,8 +35,6 @@ ram.runtime = "50M" default = "/etherpad" [install.init_main_permission] - help.en = "If enabled, Etherpad will be accessible by people who do not have an account. This can be changed later via the webadmin." - help.fr = "Si cette case est cochée, Etherpad sera accessible aux personnes n’ayant pas de compte. Vous pourrez changer ceci plus tard via la webadmin." type = "group" default = "visitors" From 1898936977ef85113b845368727c5015465d9df2 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sat, 9 Sep 2023 09:03:21 +0200 Subject: [PATCH 2/7] cleaning --- doc/ADMIN.md | 11 ++--------- doc/ADMIN_fr.md | 4 ++-- doc/DESCRIPTION.md | 3 +++ doc/DESCRIPTION_fr.md | 5 ++++- scripts/backup | 2 +- scripts/change_url | 2 +- scripts/install | 5 ++--- scripts/remove | 2 +- scripts/restore | 2 +- scripts/upgrade | 4 ++-- 10 files changed, 19 insertions(+), 21 deletions(-) diff --git a/doc/ADMIN.md b/doc/ADMIN.md index ffd8479..4dfb47b 100644 --- a/doc/ADMIN.md +++ b/doc/ADMIN.md @@ -1,10 +1,3 @@ -This version of Etherpad is installed without plugins and uses Redis as database. -Be aware, Redis database backup and restore is not fully implemented. +You can access Etherpad's admin panel at `__DOMAIN____PATH__/admin`. The configuration file for Etherpad is at the path `__INSTALL_DIR__/settings.json`. -If you want to install Etherpad with plugins and mysql database: https://github.com/YunoHost-Apps/etherpad_mypads_ynh", - -## Configuration - -You can access Etherpad's admin panel at `domain.tld/admin`. The configuration file for Etherpad is at the path `/var/www/etherpad/settings.json`. - -*Skin Builder* (accessible at this address `domain.tld/pad/p/test#skinvariantsbuilder`) allows you to customize the skin of your pad. It will give you a parameter to copy into your configuration file `/var/www/etherpad/settings.json`. +*Skin Builder* (accessible at this address `domain.tld/pad/p/test#skinvariantsbuilder`) allows you to customize the skin of your pad. It will give you a parameter to copy into your configuration file `__INSTALL_DIR__/settings.json`. diff --git a/doc/ADMIN_fr.md b/doc/ADMIN_fr.md index 827efe1..d216b09 100644 --- a/doc/ADMIN_fr.md +++ b/doc/ADMIN_fr.md @@ -1,3 +1,3 @@ -Vous pouvez accéder au panneau d'administration d'Etherpad à l'adresse `domain.tld/admin`. Le fichier de configuration d'Etherpad est `/var/www/etherpad/settings.json`. +Vous pouvez accéder au panneau d'administration d'Etherpad à l'adresse `__DOMAIN____PATH__/admin`. Le fichier de configuration d'Etherpad est `__INSTALL_DIR__/settings.json`. -*Skin Builder* (accessible à l'adresse `domain.tld/pad/p/test#skinvariantsbuilder`) vous permet de personnaliser l'apparence de votre pad. Il vous donnera un paramètre à copier dans votre fichier de configuration `/var/www/etherpad/settings.json`. +*Skin Builder* (accessible à l'adresse `__INSTALL_DIR__/pad/p/test#skinvariantsbuilder`) vous permet de personnaliser l'apparence de votre pad. Il vous donnera un paramètre à copier dans votre fichier de configuration `__INSTALL_DIR__/settings.json`. diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md index 5ecb79a..d213653 100644 --- a/doc/DESCRIPTION.md +++ b/doc/DESCRIPTION.md @@ -1 +1,4 @@ Etherpad is a real-time collaborative editor scalable to thousands of simultaneous real time users. It provides full data export capabilities, and runs on your server, under your control. +This version of Etherpad is installed without plugins and uses Redis as database. +Be aware, Redis database backup and restore is not fully implemented. +If you want to install Etherpad with plugins and mysql database: https://github.com/YunoHost-Apps/etherpad_mypads_ynh", diff --git a/doc/DESCRIPTION_fr.md b/doc/DESCRIPTION_fr.md index 519f648..e71776a 100644 --- a/doc/DESCRIPTION_fr.md +++ b/doc/DESCRIPTION_fr.md @@ -1 +1,4 @@ -Etherpad est un éditeur collaboratif en temps réel évolutif pour des milliers d'utilisateurs simultanés en temps réel. Il fournit des capacités complètes d'exportation de données et s'exécute sur votre serveur, sous votre contrôle. \ No newline at end of file +Etherpad est un éditeur collaboratif en temps réel évolutif pour des milliers d'utilisateurs simultanés en temps réel. Il fournit des capacités complètes d'exportation de données et s'exécute sur votre serveur, sous votre contrôle. +Cette version d'Etherpad est installée sans plugins et utilise Redis comme base de données. +Attention, la sauvegarde et la restauration de la base de données Redis ne sont pas entièrement implémentées. +Si vous souhaitez installer Etherpad avec les plugins et la base de données mysql : https://github.com/YunoHost-Apps/etherpad_mypads_ynh", diff --git a/scripts/backup b/scripts/backup index 7c629c7..312b053 100644 --- a/scripts/backup +++ b/scripts/backup @@ -44,4 +44,4 @@ ynh_backup --src_path="/etc/systemd/system/$app.service" # END OF SCRIPT #================================================= -ynh_print_info --message="Backup script completed for Etherpad. (YunoHost will then actually copy those files to the archive)." +ynh_print_info --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)." diff --git a/scripts/change_url b/scripts/change_url index b61f211..6898805 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -38,4 +38,4 @@ sleep 120 # END OF SCRIPT #================================================= -ynh_script_progression --message="Change of URL completed for Etherpad" --last +ynh_script_progression --message="Change of URL completed for $app" --last diff --git a/scripts/install b/scripts/install index ca91dde..c638c92 100644 --- a/scripts/install +++ b/scripts/install @@ -15,7 +15,6 @@ source /usr/share/yunohost/helpers ynh_script_progression --message="Installing dependencies..." --weight=6 ynh_install_nodejs --nodejs_version=$nodejs_version -ynh_use_nodejs #================================================= # CREATE A POSTQRESQL DATABASE @@ -40,7 +39,7 @@ chown -R $app:www-data "$install_dir" #================================================= # INSTALL ETHERPAD #================================================= -ynh_script_progression --message="Installing Etherpad..." --weight=60 +ynh_script_progression --message="Installing $app..." --weight=60 pushd $install_dir ynh_use_nodejs @@ -51,7 +50,7 @@ popd #================================================= # MODIFY A CONFIG FILE #================================================= -ynh_script_progression --message="Configuring Etherpad..." --weight=6 +ynh_script_progression --message="Configuring $app..." --weight=6 cp ../conf/settings.json $install_dir/settings.json diff --git a/scripts/remove b/scripts/remove index aa20db8..785cbfa 100644 --- a/scripts/remove +++ b/scripts/remove @@ -43,4 +43,4 @@ ynh_secure_remove --file="/var/log/$app" # END OF SCRIPT #================================================= -ynh_script_progression --message="Removal of Etherpad completed" --last +ynh_script_progression --message="Removal of $app completed" --last diff --git a/scripts/restore b/scripts/restore index 513c4a2..b132b8c 100644 --- a/scripts/restore +++ b/scripts/restore @@ -57,4 +57,4 @@ ynh_systemd_action --service_name=nginx --action=reload # END OF SCRIPT #================================================= -ynh_script_progression --message="Restoration completed for Etherpad" --last +ynh_script_progression --message="Restoration completed for $app" --last diff --git a/scripts/upgrade b/scripts/upgrade index cfee58a..f59bf9e 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -59,7 +59,7 @@ yunohost service add $app --description="Collaborative editor" --log="/var/log/$ #================================================= # INSTALL ETHERPAD #================================================= -ynh_script_progression --message="Installing Etherpad..." --weight=90 +ynh_script_progression --message="Installing $app..." --weight=90 pushd $install_dir ynh_use_nodejs @@ -80,4 +80,4 @@ ynh_systemd_action --service_name=$app --action=restart --log_path=systemd --lin # END OF SCRIPT #================================================= -ynh_script_progression --message="Upgrade of Etherpad completed" --last +ynh_script_progression --message="Upgrade of $app completed" --last From 91a6bba19ab156c2a7797a7ea9590e42152cb8e5 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Sat, 9 Sep 2023 07:03:28 +0000 Subject: [PATCH 3/7] Auto-update README --- README.md | 3 +++ README_fr.md | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index fd9b1db..0ecd5ad 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,9 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in ## Overview Etherpad is a real-time collaborative editor scalable to thousands of simultaneous real time users. It provides full data export capabilities, and runs on your server, under your control. +This version of Etherpad is installed without plugins and uses Redis as database. +Be aware, Redis database backup and restore is not fully implemented. +If you want to install Etherpad with plugins and mysql database: https://github.com/YunoHost-Apps/etherpad_mypads_ynh", **Shipped version:** 1.9.2~ynh1 diff --git a/README_fr.md b/README_fr.md index fec52e0..3236111 100644 --- a/README_fr.md +++ b/README_fr.md @@ -16,7 +16,11 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po ## Vue d’ensemble -Etherpad est un éditeur collaboratif en temps réel évolutif pour des milliers d'utilisateurs simultanés en temps réel. Il fournit des capacités complètes d'exportation de données et s'exécute sur votre serveur, sous votre contrôle. +Etherpad est un éditeur collaboratif en temps réel évolutif pour des milliers d'utilisateurs simultanés en temps réel. Il fournit des capacités complètes d'exportation de données et s'exécute sur votre serveur, sous votre contrôle. +Cette version d'Etherpad est installée sans plugins et utilise Redis comme base de données. +Attention, la sauvegarde et la restauration de la base de données Redis ne sont pas entièrement implémentées. +Si vous souhaitez installer Etherpad avec les plugins et la base de données mysql : https://github.com/YunoHost-Apps/etherpad_mypads_ynh", + **Version incluse :** 1.9.2~ynh1 From ac86cc9dac53e99c2b070aefdd150d191a961661 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 9 Sep 2023 11:17:39 +0200 Subject: [PATCH 4/7] Update tests.toml --- tests.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests.toml b/tests.toml index 23a2b1f..ab97358 100644 --- a/tests.toml +++ b/tests.toml @@ -6,4 +6,4 @@ test_format = 1.0 # Commits to test upgrade from # ------------------------------- - test_upgrade_from.96653aee9379d579a655777ac274355f4afca61c.name = "Upgrade from 5.4" \ No newline at end of file + #test_upgrade_from.96653aee9379d579a655777ac274355f4afca61c.name = "Upgrade from 5.4" \ No newline at end of file From 4d96db40eb67409447804cfd1e238b1ef26f383b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 9 Sep 2023 11:33:22 +0200 Subject: [PATCH 5/7] cleaning --- scripts/install | 11 +++++------ scripts/upgrade | 5 +---- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/scripts/install b/scripts/install index c638c92..0b7f47f 100644 --- a/scripts/install +++ b/scripts/install @@ -43,7 +43,6 @@ ynh_script_progression --message="Installing $app..." --weight=60 pushd $install_dir ynh_use_nodejs - #ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/run.sh ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh popd @@ -52,10 +51,10 @@ popd #================================================= ynh_script_progression --message="Configuring $app..." --weight=6 -cp ../conf/settings.json $install_dir/settings.json +ynh_add_config --template="../conf/settings.json" --destination="$install_dir/settings.json" +chmod 400 "$install_dir/settings.json" +chown $app:$app "$install_dir/settings.json" -ynh_replace_string --match_string="__PORT__" --replace_string="$port" --target_file="$install_dir/settings.json" -ynh_replace_string --match_string="__LANGUAGE__" --replace_string="$language" --target_file="$install_dir/settings.json" if [ "$export" = "abiword" ] then # Get AbiWord binary path @@ -72,8 +71,8 @@ fi ynh_store_file_checksum --file="$install_dir/settings.json" ynh_add_config --template="../conf/credentials.json" --destination="$install_dir/credentials.json" - -chmod 400 $install_dir/credentials.json +chmod 400 "$install_dir/credentials.json" +chown $app:$app "$install_dir/credentials.json" #================================================= # SETUP SYSTEMD diff --git a/scripts/upgrade b/scripts/upgrade index f59bf9e..6614e6c 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -32,7 +32,7 @@ if [ "$upgrade_type" == "UPGRADE_APP" ] then ynh_script_progression --message="Upgrading source files..." --weight=1 # Download, check integrity, uncompress and patch the source from app.src - ynh_setup_source --dest_dir="$install_dir" --keep="$install_dir/settings.json $install_dir/credentials.json" + ynh_setup_source --dest_dir="$install_dir" --keep="settings.json credentials.json" fi chmod -R o-rwx "$install_dir" @@ -63,10 +63,7 @@ ynh_script_progression --message="Installing $app..." --weight=90 pushd $install_dir ynh_use_nodejs - #ynh_exec_warn_less ynh_exec_as $app env "$ynh_node_load_PATH" src/bin/run.sh ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh - #ynh_exec_warn_less ynh_exec_as $app env "$ynh_node_load_PATH" npm cache clean --force - #ynh_exec_warn_less ynh_exec_as $app env "$ynh_node_load_PATH" npm install --upgrade popd #================================================= From c00327653287872d7dc76a2eb01d0acf6a1bfcfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 9 Sep 2023 11:34:59 +0200 Subject: [PATCH 6/7] fix --- scripts/remove | 2 +- scripts/upgrade | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/remove b/scripts/remove index 785cbfa..22c2052 100644 --- a/scripts/remove +++ b/scripts/remove @@ -19,7 +19,7 @@ ynh_script_progression --message="Removing system configurations related to $app # Remove the service from the list of services known by YunoHost (added from `yunohost service add`) if ynh_exec_warn_less yunohost service status $app >/dev/null then - ynh_script_progression --message="Removing Etherpad service integration..." --weight=2 + ynh_script_progression --message="Removing $app service integration..." --weight=2 yunohost service remove $app fi diff --git a/scripts/upgrade b/scripts/upgrade index 6614e6c..a56a458 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -22,7 +22,7 @@ upgrade_type=$(ynh_check_app_version_changed) #================================================= ynh_script_progression --message="Stopping a systemd service..." --weight=42 -ynh_systemd_action --service_name=$app --action=stop --log_path="/var/log/$app/$app.log" +ynh_systemd_action --service_name=$app --action=stop --log_path="systemd" #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE From 1ff33c5a2ac72fb389013c01b1d1022aa14d31cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 9 Sep 2023 11:35:53 +0200 Subject: [PATCH 7/7] Update nginx.conf --- conf/nginx.conf | 1 - 1 file changed, 1 deletion(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 4b1646c..7c00030 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -5,7 +5,6 @@ location __PATH__/ { proxy_set_header Host $host; proxy_pass_header Server; - # be careful, this line doesn't override any proxy_buffering on set in a conf.d/file.conf proxy_buffering off; more_set_headers "X-Frame-Options : ALLOWALL"; proxy_set_header X-Real-IP $remote_addr; # http://wiki.nginx.org/HttpProxyModule