يتم طلب رد اتصال HTTP OAuth حتى إذا تم تفعيل HTTPS

I have HTTPS enabled on my site, enforced by a 301 redirect from HTTP to HTTPS by the reverse proxy in front of it. When I tried to login with Google, Google complained that the requested callback URL did not match the registered callback URL, the difference being that the registered callback URL uses HTTPS, and the requested URL uses HTTP…

That would be the cause, you need to ensure NGINX has the headers set correctly, when we need to enforce this we add:

 - replace:
         filename: /etc/nginx/conf.d/discourse.conf
         from: $thescheme;
         to: https;
         global: true
إعجابَين (2)

Where does that go? I tried adding it web_only.yml, under

hooks:
  after_code:

And got

Errno::ENOENT: No such file or directory - /etc/nginx/conf.d/discourse.conf

after_web_config:

https://github.com/discourse/discourse_docker/blob/master/templates/web.template.yml#L121

إعجاب واحد (1)

This topic was automatically closed after 3273 days. New replies are no longer allowed.