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 1/5] [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 2/5] [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 3/5] [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 4/5] [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 5/5] 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