Nextcloud has issued fix for a .conf issue. How to manually apply to Yunohost?

So, it seems that in Nextcloud version 27.1.2 there’s a bit of a bug with the default nextcloud.conf file which causes an error to show in the admin panel saying: “Your web server is not properly set up to resolve “/nextcloud/ocm-provider/””

There has been a patch merged which changes out this:

rewrite ^/(?!index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+|.+\/richdocumentscode\/proxy) /index.php$request_uri;

For this:
rewrite ^/(?!index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|ocs-provider\/.+|.+\/richdocumentscode\/proxy) /index.php$request_uri;

The trouble is I don’t see that first line, or a lot of the default Nextcloud configuration, to replace anywhere in my /etc/php/8.2/fpm/pool.d/nextcloud.conf ,which looks like this:

user = nextcloud
group = nextcloud

chdir = /var/www/nextcloud

listen = /var/run/php/php8.2-fpm-nextcloud.sock
listen.owner = www-data = www-data

pm = dynamic
pm.max_children = 8
pm.max_requests = 500
request_terminate_timeout = 1d

pm.start_servers = 3
pm.min_spare_servers = 2
pm.max_spare_servers = 4

; Additional php.ini defines, specific to this pool of workers.
env[PATH] = $PATH
php_admin_value[memory_limit] = 512M
php_value[upload_max_filesize] = 10G
php_value[post_max_size] = 10G
php_value[default_charset] = UTF-8
; OPcache is already activated by default
; php_value[opcache.enable]=1
; The following parameters are nevertheless recommended for Nextcloud
; see here:

So I guess I have 2 questions:

  1. How can I apply this fix manually?
  2. Is it safe that my .conf file doesn’t seem to include any of Nextcloud’s default location rewrites? Is that something handled elsewhere in Yunohost?

This is to be applied to the Nextcloud NGINX config not the PHP.

1 Like

You could upgrade to this branch : Fix ocs-provider warning by ericgaspar · Pull Request #607 · YunoHost-Apps/nextcloud_ynh · GitHub

1 Like

Thank you so much @ericg / @Lapineige ! With your combined help, it’s now working perfectly. :grin: I just wish I could mark both answers as correct, as they both helped!

For anyone else looking to fix this, just check the two posts above. :slight_smile:

Screenshot of a circled, green checkmark/tick. Next to it it says "All checks passed".

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.