Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error connecting to websocket #3041

Closed
stanthewizzard opened this issue Aug 21, 2017 · 11 comments
Closed

Error connecting to websocket #3041

stanthewizzard opened this issue Aug 21, 2017 · 11 comments
Labels

Comments

@stanthewizzard
Copy link

Medusa Info: Branch: masterCommit: 49e9fc38856200768d41a74139807886acefa054Version: v0.1.14Database: 44.8
Debian 8.9
Python Version: 2.7.12 (default, Nov 19 2016, 06:48:10) [GCC 5.4.0 20160609]
SSL Version: OpenSSL 1.0.2g 1 Mar 2016
OS: Linux-4.4.0-66-generic-x86_64-with-Ubuntu-16.04-xenial
Locale: fr_FR.UTF-8

Hello
I get this notification error
Error connecting to webscoket
Behind Nginx and with direct IP access

Someone got this issue too ?

Thanks

@OmgImAlexis
Copy link
Collaborator

@p0psicles
Copy link
Contributor

With a correct configured nginx reversed proxy this should be fixed in current develop.
Won't be long until that's merged to master.

@stanthewizzard
Copy link
Author

I got the issue through IP direct
bypassing nginx totaly
:/

@OmgImAlexis
Copy link
Collaborator

The websocket is likely trying to use wss which requires ssl. It will work fine with nginx if you add the websocket details on the page I linked.

@stanthewizzard
Copy link
Author

Already added ...
no change of behavior

@stanthewizzard
Copy link
Author

server {
listen 80;
server_name grabbing2.test.com;
return 301 https://$server_name$request_uri;
}
server {
listen 443;
server_name grabbing2.test.com;
include /etc/nginx/conf.d/ssl.conf;
access_log /var/log/nginx/grabbing-access.log;
error_log /var/log/nginx/grabbing-error.log;

location ^~ /medusa {
proxy_pass http://localhost:8082;
include /etc/nginx/global.d/proxy.conf;
# Websocket
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
}

In the proxy.conf

Advanced Proxy Config

proxy_connect_timeout 86400;
proxy_send_timeout 86400;
proxy_read_timeout 86400;
send_timeout 86400;

Basic Proxy Config

proxy_set_header Host $host;
#proxy_set_header X-Forwarded-Proto https;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $host:443;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-Port 443;
proxy_set_header X-Forwarded-Proto $scheme;

@p0psicles
Copy link
Contributor

Are u using a webroot?

@stanthewizzard
Copy link
Author

sorry I don't understand what it is ? :)

@p0psicles
Copy link
Contributor

are you running default using a root like this: http://localhost:8082/home/... or did you have a base configured like: http://localhost:8082/medusa/home/...

@p0psicles
Copy link
Contributor

I suspect you have the webroot configured, and then you'll need to wait for our next release to have this fixed. Or checkout develop branch.

@stanthewizzard
Copy link
Author

OK I understand (thanks)
No it's a root web dir.
Configured like that
http://localhost:8082/medusa/home/...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants