Problem setting up Discourse with docker behind Nginx reverse proxy. Encountering SPDY protocol error

I’m trying to setup Discourse on my existing server that has a running Nginx. I’ve used the Discourse Docker launcher program for my setup, which seems to have another intermediate Nginx proxy inside.

After the setup, I can see the account setup page properly.

But after I clicked the email link, I’ve been directed to an account activation page with JS error. Turning on my developer console on Chrome, Ive got these errors:

  • Failed to load resource: net::ERR_SPDY_PROTOCOL_ERROR
    /stylesheets/desktop_…css:1
  • Failed to load resource: net::ERR_SPDY_PROTOCOL_ERROR
    /vendor-…js:1
  • Failed to load resource: net::ERR_SPDY_PROTOCOL_ERROR
    /ember_jquery-…js:1
  • Uncaught ReferenceError: $ is not defined
    at …:81

And apparently, the “Click here to activate your account” button does nothing because the js files are failed to loaded.

What is going on? Any advice on how to fix this?


Update 1: I have changed the reverse proxy to point to localhost:3000 (the rails port). The problem still exists. So the nginx in the docker plays no role in the error. In case it it relevant, I have Let’s Encrypt certificate setup on the host’s Nginx.

Update 2: I forgot I also have a Cloudflare in front of my Nginx. And apparently, the problem is gone when I disable the CDN there.

After some test, I found that the problem related to neither nginx nor discourse. It seems to be a Cloudflare issue. I have filed the issue here if you’re interested.

2 Likes

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