isso-comments / isso

a Disqus alternative
https://isso-comments.de
MIT License
5.06k stars 438 forks source link

Gunicorn, isso, multiple domains: "WARNING: unable to connect to your website, Isso will probably not work correctly." #160

Closed lumenwrites closed 7 years ago

lumenwrites commented 9 years ago

Hi! I am trying to setup isso on 2 domains. I am using gunicorn.

When I am using only one config, such as:

export ISSO_SETTINGS="/root/isso/site1.cfg"
gunicorn -b localhost:8080 -w 4 --preload isso.run

everything works correctly, but when I'm trying to enable 2 configs:

export ISSO_SETTINGS="/root/isso/site1.cfg;/root/isso/site2.cfg"
gunicorn -b localhost:8080 -w 4 --preload isso.run

I get an warning:

WARNING: unable to connect to your website, Isso will probably not work correctly. Please make sure, Isso can reach your website via HTTP(S).

And comments don't work, giving me this error:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at http://comments.site1.com/?uri=link-to-my-article&nested_limit=5. This can be fixed by moving the resource to the same domain or enabling CORS.

Can you help me out? Am I doing something wrong?

lumenwrites commented 9 years ago

Oh, my mistake, I should've used

gunicorn -b localhost:8080 -w 4 --preload isso.dispatch

instead of

gunicorn -b localhost:8080 -w 4 --preload isso.run

Now I'm not getting the warning and script embed.dev.js seems to load correctly, but I'm still getting the Cross-Origin Request Blocked.

Can you help me figure out what can be wrong here?

posativ commented 9 years ago

You can check if the CORS headers in the browser's network console match your specified site in your configuration(s). If that is not the cause, it is due to a wrong configuration.

E.g. if you want Isso to run for example.org on host isso.example.org, you have to put *example.org into the host section.

blatinier commented 7 years ago

No update for 2 years. I suppose it's OK to close.