Question about Nginx Proxy Manager behind Nextcloud Hub 25 32.0.6

Hello everyone,

I performed a fresh installation using the LAMP stack on an Ubuntu 24.04.4 LTS system. I’m using Nginx Proxy Manager as my proxy.

Currently, Nextcloud is accessible via HTTP, and the nginx proxy manager provides the certificate. The Nextcloud URL is http://10.10.110.1 and the URL via the reverse proxy is https://cloud.example.com

Is this recommended, or would it make more sense to issue an additional certificate to Nextcloud itself, make it accessible via HTTPS, and use the proxy in front of that?

What are the correct settings in the custom Nginx configuration for Nextcloud?

The Basics

  • Nextcloud Server version (e.g., 29.x.x):
    • 32.0.6
  • Operating system and version (e.g., Ubuntu 24.04):
    • Ubuntu24.04.4 LTS
  • Web server and version (e.g, Apache 2.4.25):
    • Apache/2.4.58
  • Reverse proxy and version _(e.g. nginx 1.27.2)
    • NgingX Proxy Managerv2.13.7
  • PHP version (e.g, 8.3):
    • 8.3
  • Is this the first time you’ve seen this error? (Yes / No):
    • replace me
  • When did this problem seem to first start?
    • replace me
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
    • Proxmox VM Ubuntu 24.04.4 LTS LAMP STACK
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)
    • No

What you’re doing is fairly typical. It’s quite common - probably most common - to not use HTTPS between a reverse proxy and the backend services (e.g. Nextcloud). This is typically fine because the reverse proxy and backend services are usually co-located (i.e. same network if not the same host).

What are the correct settings in the custom Nginx configuration for Nextcloud?

The AIO Nextcloud stack suggests these for when using NPM as a reverse proxy, which are probably reasonable generic baselines:

client_body_buffer_size 512k;
proxy_read_timeout 86400s;
client_max_body_size 0;

Hey @jtr ,

thanks for the quick reply. I have a Nextcloud installation using the LAMP stack, not Nextcloud AIO. Are the settings for the AIO stack and the LAMP stack identical? Can I use the settings for the LAMP stack as well ?

Regards

Yes, in this case. Technically those parameters are mentioned in the standard Admin Manual in a couple spots too. However they’re not well documented in a single spot for Reverse Proxy scenarios unless you know what you’re looking for already.