From beb3eacc9a64be29ef446469f2ffe05b8b4f06ad Mon Sep 17 00:00:00 2001 From: OniriCorpe Date: Thu, 30 Nov 2023 01:09:03 +0100 Subject: [PATCH 01/12] augment "opcache.revalidate_freq" from 1 to 60 (#541) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * [enh] revalidate_freq to 60 --------- Co-authored-by: Éric Gaspar <46165813+ericgaspar@users.noreply.github.com> Co-authored-by: ljf (zamentur) --- conf/extra_php-fpm.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/extra_php-fpm.conf b/conf/extra_php-fpm.conf index feee90b..fd92447 100644 --- a/conf/extra_php-fpm.conf +++ b/conf/extra_php-fpm.conf @@ -14,7 +14,7 @@ php_value[opcache.interned_strings_buffer]=32 php_value[opcache.max_accelerated_files]=10000 php_value[opcache.memory_consumption]=128 php_value[opcache.save_comments]=1 -php_value[opcache.revalidate_freq]=1 +php_value[opcache.revalidate_freq]=60 ; https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/caching_configuration.html#id1 php_value[apc.enabled]=1 php_value[apc.enable_cli]=1 From 8efdae92176cc29d27291db752c6c97709b5f86b Mon Sep 17 00:00:00 2001 From: "ljf (zamentur)" Date: Thu, 30 Nov 2023 11:45:53 +0100 Subject: [PATCH 02/12] [fix] overwrite.cli.url should contains path --- scripts/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/install b/scripts/install index 2f16071..a169962 100755 --- a/scripts/install +++ b/scripts/install @@ -198,7 +198,7 @@ exec_occ config:system:get logout_url >/dev/null 2>&1 \ # CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS #================================================= -exec_occ config:system:set overwrite.cli.url --value="https://${domain}" +exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" #================================================= # REMOVE THE TEMPORARY ADMIN AND SET THE TRUE ONE From ac91d3a6769747fd3819484ae8c02446e5cc0a30 Mon Sep 17 00:00:00 2001 From: "ljf (zamentur)" Date: Thu, 30 Nov 2023 11:48:18 +0100 Subject: [PATCH 03/12] [fix] Upgrade the bad overwrite.cli.url with path --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 85ab559..aac8c8d 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -312,7 +312,7 @@ EOF # CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS #================================================= - exec_occ config:system:set overwrite.cli.url --value="https://${domain}" + exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" #================================================= # MOUNT HOME FOLDERS AS EXTERNAL STORAGE From f0100c7fcbe712b757c0dac135ce6f928b19bca5 Mon Sep 17 00:00:00 2001 From: narF Date: Thu, 30 Nov 2023 14:26:21 -0500 Subject: [PATCH 04/12] Update ADMIN.md --- doc/ADMIN.md | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/doc/ADMIN.md b/doc/ADMIN.md index ef43357..0f1d6a1 100644 --- a/doc/ADMIN.md +++ b/doc/ADMIN.md @@ -6,16 +6,14 @@ or use `sudo yunohost app shell __APP__` then run `php occ ...` ### Configure ONLYOFFICE integration -#### With Nextcloud App (no ARM support, lower performance) +#### With YunoHost App (ARM64 support, better performance) + +For better performance and ARM64 support (Raspberry Pi, OLinuXino...), install ONLYOFFICE YunoHost App and connect it to Nextcloud, see the tutorial in the [doc of onlyoffice_ynh package](https://github.com/YunoHost-Apps/onlyoffice_ynh/blob/master/README_fr.md#configuration-de-onlyoffice-server) + +#### Alternative: With Nextcloud App (no ARM support, lower performance) Nextcloud features a direct integration of ONLYOFFICE (an online rich text document editor) through a Nextcloud app. To install and configure it: - Install *Community Document Server* application in your Nextcloud. That's the part that runs ONLYOFFICE server. - Install *ONLYOFFICE* application. That's the client part that will connect to an ONLYOFFICE server. - Then in Settings -> ONLYOFFICE (`https://__DOMAIN____PATH__/settings/admin/onlyoffice`), if you want to configure which file formats should be opened by ONLYOFFICE. - -*NB: ONLYOFFICE Nextcloud App is only available for x86 architecture - for **ARM** architecture (Raspberry Pi, OLinuXino...), consider the YunoHost App below* - -#### With YunoHost App (ARM64 support, better performance) - -For better performance and ARM64 support, install ONLYOFFICE YunoHost App and connect it to Nextcloud, see the tutorial in the [doc of onlyoffice_ynh package](https://github.com/YunoHost-Apps/onlyoffice_ynh/blob/master/README_fr.md#configuration-de-onlyoffice-server) From 3f979a4fa8bc66594b984ce1930d46a07248466f Mon Sep 17 00:00:00 2001 From: narF Date: Thu, 30 Nov 2023 14:27:57 -0500 Subject: [PATCH 05/12] Update ADMIN_fr.md --- doc/ADMIN_fr.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/ADMIN_fr.md b/doc/ADMIN_fr.md index c617ce3..3a691ba 100644 --- a/doc/ADMIN_fr.md +++ b/doc/ADMIN_fr.md @@ -6,7 +6,11 @@ ou utilisez `sudo yunohost app shell __APP__` puis `php occ ...` ### Configurer l'intégration d'ONLYOFFICE -#### Avec l'application Nextcloud (pas de support ARM, performances limitées) +#### Avec l'application YunoHost (support ARM64, meilleures performances) + +Pour de meilleures performances et le support de ARM64 (Raspberry Pi, OLinuXino...), installez l'app YunoHost ONLYOFFICE, voir le tutoriel dans la [doc du paquet onlyoffice_ynh](https://github.com/YunoHost-Apps/onlyoffice_ynh/blob/master/README_fr.md#configuration-de-onlyoffice-server) + +#### Alternative: Avec l'application Nextcloud (pas de support ARM, performances limitées) Nextcloud inclut une intégration directe de ONLYOFFICE (un éditeur de texte enrichi en ligne) via une application Nextcloud. Pour l'installer et la configurer : @@ -14,8 +18,4 @@ Pour l'installer et la configurer : - Installez l'application *ONLYOFFICE*. C'est la partie cliente qui va se connecter au serveur ONLYOFFICE. - Ensuite dans les Paramètres -> ONLYOFFICE (`https://__DOMAIN____PATH__/settings/admin/onlyoffice`), si vous voulez configurer quels formats de fichier s'ouvrent avec ONLYOFFICE. -*NB : l'app Nextcloud ONLYOFFICE Community Document Server n'est disponible que sous architecture x86 - Pour un support de l'architecture **ARM** (Raspberry Pi, OLinuXino...), installez plutôt l'App YunoHost, voir ci-dessous* - -#### Avec l'application YunoHost (support ARM64, meilleures performances) - -Pour de meilleures performances et le support de ARM64, installez l'app YunoHost ONLYOFFICE, voir le tutoriel dans la [doc du paquet onlyoffice_ynh](https://github.com/YunoHost-Apps/onlyoffice_ynh/blob/master/README_fr.md#configuration-de-onlyoffice-server) +*NB : l'app Nextcloud ONLYOFFICE Community Document Server n'est disponible que sous architecture x86 From d1fc31add28bdb6ac4490cd0376ac78f4cd8cda8 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sat, 2 Dec 2023 08:55:59 +0100 Subject: [PATCH 06/12] Update POST_UPGRADE.md --- doc/POST_UPGRADE.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/POST_UPGRADE.md b/doc/POST_UPGRADE.md index 7da1480..b0a56e5 100644 --- a/doc/POST_UPGRADE.md +++ b/doc/POST_UPGRADE.md @@ -1 +1 @@ -Note that if you've installed some third-parties Nextcloud applications, they are probably disabled and you'll have to manually enable them again. \ No newline at end of file +Note that if you've installed any third-party Nextcloud applications, they have probably been disabled. If so, you'll need to manually enable them again. From 5d4f8a37302ea63b12b7848edb0b65d619d07d11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 4 Dec 2023 16:24:03 +0100 Subject: [PATCH 07/12] Update change_url --- scripts/change_url | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/change_url b/scripts/change_url index 0d8a142..0d8c794 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -33,7 +33,7 @@ then exec_occ config:system:set trusted_domains 1 --value=$new_domain # Change hostname for activity notifications - exec_occ config:system:set overwrite.cli.url --value="https://${new_domain}" + exec_occ config:system:set overwrite.cli.url --value="https://${new_domain}${new_path}" fi if [ $change_domain -eq 1 ] From 5c7d41f9a5d687e7d261cce647b89ee3a722a27f Mon Sep 17 00:00:00 2001 From: eric_G <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 9 Dec 2023 01:39:03 +0100 Subject: [PATCH 08/12] [fix] Api permission (#633) --- scripts/change_url | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/change_url b/scripts/change_url index 0d8c794..6da4c8d 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -49,6 +49,14 @@ then fi fi +#================================================= +# SETUP SSOWAT +#================================================= +ynh_script_progression --message="Configuring permissions..." + +# Temporary fix for the API permission +ynh_permission_url --permission="api" --url="re:$new_domain\/.well-known\/.*" --auth_header="false" --clear_urls + #================================================= # END OF SCRIPT #================================================= From e4a27e8ea48db392e22504ceb72ceddc7127170e Mon Sep 17 00:00:00 2001 From: ljf Date: Sat, 9 Dec 2023 23:57:08 +0100 Subject: [PATCH 09/12] [fix] php8.1 not found on nc25 -> nc27 upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index aac8c8d..186a0bd 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -119,7 +119,7 @@ exec_occ() { fi if ! timeout 1 php$NEXTCLOUD_PHP_VERSION 2>/dev/null; then local pkg_dependencies="$(dpkg-query --show --showformat='${Depends}' ${app}-ynh-deps)" - pkg_dependencies="${pkg_dependencies/$phpversion/$NEXTCLOUD_PHP_VERSION}" + pkg_dependencies="${pkg_dependencies//$phpversion/$NEXTCLOUD_PHP_VERSION}" ynh_install_app_dependencies "$pkg_dependencies" fi (cd "$install_dir" && ynh_exec_as "$app" \ From a4480d7da6dca319b2b7b958a4f6d47d9a2a0545 Mon Sep 17 00:00:00 2001 From: "ljf (zamentur)" Date: Mon, 11 Dec 2023 01:32:39 +0100 Subject: [PATCH 10/12] [fix] Multimedia and home external storage --- scripts/install | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/install b/scripts/install index a169962..c1b9599 100755 --- a/scripts/install +++ b/scripts/install @@ -160,10 +160,10 @@ exec_occ ldap:test-config '' \ # Define a function to add an external storage # Create the external storage for the given folders and enable sharing create_external_storage() { - local datadir="$1" + local mount_dir="$1" local mount_name="$2" local mount_id=`exec_occ files_external:create --output=json \ - "$mount_name" 'local' 'null::null' -c "datadir=$data_dir/data" || true` + "$mount_name" 'local' 'null::null' -c "datadir=$mount_dir" || true` ! [[ $mount_id =~ ^[0-9]+$ ]] \ && ynh_print_warn --message="Unable to create external storage" \ || exec_occ files_external:option "$mount_id" enable_sharing true From 1fd9f6d2f84f22c413a2d06b04a7adda8950dd98 Mon Sep 17 00:00:00 2001 From: "ljf (zamentur)" Date: Mon, 11 Dec 2023 01:35:32 +0100 Subject: [PATCH 11/12] [fix] Mount multimedia and home in upgrade script --- scripts/upgrade | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 186a0bd..32c7001 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -129,10 +129,10 @@ exec_occ() { # Define a function to add an external storage # Create the external storage for the given folders and enable sharing create_external_storage() { -local datadir="$1" +local mount_dir="$1" local mount_name="$2" local mount_id=$(exec_occ files_external:create --output=json \ - "$mount_name" 'local' 'null::null' -c "datadir=$data_dir/data" || true) + "$mount_name" 'local' 'null::null' -c "datadir=$mount_dir" || true) ! [[ $mount_id =~ ^[0-9]+$ ]] \ && ynh_print_warn --message="Unable to create external storage" \ || exec_occ files_external:option "$mount_id" enable_sharing true From 24fb207ce52bacbaf9d55f3d774f09468ee24dc0 Mon Sep 17 00:00:00 2001 From: Thatoo Date: Sun, 17 Dec 2023 12:48:03 +0100 Subject: [PATCH 12/12] Update nginx.conf To allow to be followed in Social app. However, still can't follow others. --- conf/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index d09ac20..1750d6a 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -9,7 +9,7 @@ location ^~ /.well-known { location = /.well-known/carddav { return 301 __PATH__/remote.php/dav/; } location = /.well-known/caldav { return 301 __PATH__/remote.php/dav/; } - location = /.well-known/webfinger { return 301 __PATH__/index.php$uri; } + location = /.well-known/webfinger { return 301 __PATH__/index.php$request_uri; } location = /.well-known/nodeinfo { return 301 __PATH__/index.php$uri; } # Let Nextcloud's API for `/.well-known` URIs handle all other