Cannot get Discourse to install behind Nginx-proxy-manager

I tried deploying (locally, via a hypervisor host) a VM running Ubuntu Server 18.04 to run Discourse.

The issue is when I attempt to forward traffic going to domain.xyz to address x.x.x.x and using certs installed / created locally on nginx-proxy-manager.

The installer (For discourse) refuses to acknowledge port 443 is open, and when checking the authenticity of the domain it fails every time stating that 443 is unreachable, and that 80 IS reachable.

image

As for testing it myself, I get error 502’s via Chrome, indicating the web server is DOWN. Which is odd. It must be hunting for a file or something when it runs that test. ¯\_(ツ)_/¯

I’ve attempted manually setting configuration options in app.yml as described in the official documentation for hosting it alongside other applications. I’ve also tried manually building via ./discourse-doctor, and again no dice. Docker container comes up, but nothing is displayed via web browser (NGINX err 502)

In terms of configuration of the NGINX reverse proxy, I don’t get many options. It’s all GUI-based, simplifying the process. For the most part, other services like Bitwarden, NextCloud and Restya all worked right out of the box, but Discourse is being really picky or something because regardless of what I tried, nothing seems to work.

Configuration wise, I’ve set it up like so:

And for SSL I have it using a cert that is applied from the NGINX-Proxy server atop of Discourse or whatever application I’m running.

(To clarify, the reverse proxy server is a SEPARATE VM also running Ubuntu 18.04 and Nginx-Proxy-Manager a solution for managing multiple NGINX Reverse Proxy Setups.)

If you’re doing a reverse proxy you’re on your own. You’ll need to edit app.yml accordingly and do a ./launcher rebuild app.

1 Like

OK Figured it out.

For users like me who have a separate VM / Host / Whatever for running their NGINX server no custom flags or features have to be turned on.

Simply just point your domain at your IP, configure NGINX to route that hostname to your Discourse server and it should just work. (Mind if you use SSL, then configure accordingly.)

Cannot believe I wasted 5+ hours on that, fiddling and tinkering to realize the default settings worked just fine.

3 Likes

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