# Nextcloud bare metal installation already configured but move to NGINX Proxy Manager

**URL:** <https://help.nextcloud.com/t/nextcloud-bare-metal-installation-already-configured-but-move-to-nginx-proxy-manager/215857>\
**Category:** ℹ️ Support\
**Tags:** baremetal, nextcloud, npm, nc30, turn, talk-app, cloudflare\
**Created:** [January 24, 2025, 4:08pm UTC](https://help.nextcloud.com/t/nextcloud-bare-metal-installation-already-configured-but-move-to-nginx-proxy-manager/215857 "2025-01-24T16:08:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Michiel\_Breur](https://help.nextcloud.com/user_avatar/help.nextcloud.com/michiel_breur/32/67642_2.png) [@Michiel\_Breur](https://help.nextcloud.com/u/Michiel_Breur)\
**Post date:** [January 24, 2025, 4:08pm UTC](https://help.nextcloud.com/t/nextcloud-bare-metal-installation-already-configured-but-move-to-nginx-proxy-manager/215857/1 "2025-01-24T16:08:25Z")

</div>

Hello,

Skipping the support guide.

Installation :

- Nextcloud 30.0.5
- Apache2

I had everything installed but ran most of my local network through ‘hosts’ edits (192.168.1.2 myserver.domain.eu) and i had to enter the port manually. like myserver.domain.eu:8888.

I already configured Nextcloud+Collabera+SSL/TLS and .htaccess to be on port 80/443 before, however NPM needs to be there. So i forwarded those ports to NPM and all was fine i thought since it worked when i tried it on my LAN.

When i use my phones data connection to test it remotely:  
Chrome :  
-ERR\_SSL\_UNRECOGNIZED\_NAME\_ALERT  
When i turn on SSL with \*.domain.eu on NPM:  
-502 Bad Gateway  
When i turn on Cloudflare proxy for ‘nc.mydomain.eu’ :  
with force SSL/http2/hsts on in NPM:  
-ERR\_TOO\_MANY\_REDIRECTS  
with SSL off in NPM:  
Bad Gateway (cloudflare page)

When i turn on VPN on my phone which goes to my wireguard instance it works fine again since it’s local.  
I’m afraid when i remove the Certs it will stop working altogether.  
Seeing everything else is working i assume it’s a configuration thing with Nextcloud.  
I read this part :  
[https://docs.nextcloud.com/server/30/admin\_manual/configuration\_server/reverse\_proxy\_configuration.html](https://docs.nextcloud.com/server/30/admin_manual/configuration_server/reverse_proxy_configuration.html)  
But i have no clue on how to apply this in my situation?

I already put this line in:  
‘trusted\_proxies’ =\>  
array (  
0 =\> ‘192.168.1.5’,

but that doesn’t seem to work.

Also recently this message shows up :  
Some headers are not set correctly on your instance - The `Strict-Transport-Security` HTTP header is not set (should be at least `15552000` seconds). For enhanced security, it is recommended to enable HSTS. For more details see the [documentation ↗](https://docs.nextcloud.com/server/30/go.php?to=admin-security)

And checked my 'nextcloud-le-ssl.conf : Header always set Strict-Transport-Security “max-age=63072000; includeSubDomains; preload”  
I don’t recall changing that before but that looks like a lot more then 15552000.

I don’t know if that occ:rewrite:security (forgot exact command) changed it?

---

<div class="post-metadata">

**Author:** ![system](https://help.nextcloud.com/user_avatar/help.nextcloud.com/system/32/29333_2.png) [@system](https://help.nextcloud.com/u/system)\
**Post date:** [April 24, 2025, 4:09pm UTC](https://help.nextcloud.com/t/nextcloud-bare-metal-installation-already-configured-but-move-to-nginx-proxy-manager/215857/2 "2025-04-24T16:09:08Z")

</div>

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