Bad Gateway error on NGINX


I have a DO server setup with a Wordpress site and Discourse. I have rencently made the move to SSL.

I went through and followed the guide here:

And the DO guide here

Either guide is giving me a bad gateway error when I try to go to SSL for the Discourse site.

My Setup:

Curently running NGINX 1.10.0 which is hosting my wordpress site ( and proxy to my Discourse site ( I created two separate certs through Let’s Encrypt. One for and one for My wordpress site is up and running with the cert today. When I try to change the NGINX config for the discourse site to use the cert I get a bad gateway error. Discourse is listening on port 85.

Here is my NGINX config for the discourse site. The commented out sever block is what is live today and working. The two blocks below are what I am trying to go to. Appreciate any guidance thanks.

Got it working.

Figured out my issue. Also merged into single cert. Don’t know why I thought I needed two.

My working config

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