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

Server doesn't allow connections #7

Closed
digitalhuman opened this issue Jul 22, 2018 · 6 comments
Closed

Server doesn't allow connections #7

digitalhuman opened this issue Jul 22, 2018 · 6 comments
Assignees

Comments

@digitalhuman
Copy link
Contributor

This is the only output I get.

Logger::enable();
        
        (new Server('0.0.0.0', 2083, 6, true))
            ->setCert()
            ->setPassPhrase()
            ->setHandler(SocketHandler::class)
            ->run();
php artisan chat:socket-server
I'm: #12051
I'm: #12052
I'm: #12053
I'm: #12054
I'm: #12056
I'm: #12055
@digitalhuman
Copy link
Contributor Author

WebSocket connection to 'ws://kryb.thecodingcompany.nl:9000/' failed: Error during WebSocket handshake: Unexpected response code: 502

@alexslipknot
Copy link
Member

alexslipknot commented Jul 22, 2018

You are starting server on port 2083. And then trying to connect to it on port 9000 :)
Change the whole settings (Cause I see you also trying to enable WSS (WS + SSL) but then connecting to ws:// instead of wss://).

@digitalhuman
Copy link
Contributor Author

Nope that was just old code ;)

nGinx is listing on 9000 and loadbalance it to 127.0.0.1:90 addresses.

(new Server('127.0.0.1', 90, 6, true))
->setCert()
->setPassPhrase()
->setHandler(SocketHandler::class)
->run();

@digitalhuman
Copy link
Contributor Author

I am also on Skype, Signal, Telegram if you find that easier ;) Just let me know.

@alexslipknot
Copy link
Member

Found you on Skype :)
I don't know what the settings on nginx, but first you can try to connect to server without proxy (in your case port 90)

@alexslipknot alexslipknot self-assigned this Jul 22, 2018
@digitalhuman
Copy link
Contributor Author

lol, so, when not using SSL, don't forget the 'true' parameter when starting the server :)

(new Server('0.0.0.0', 9000, 6, true)) <---

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

No branches or pull requests

2 participants