I'm usingVagrantbox using puphpet, the environment is PHP 5.5 + ubuntu 12.04 + apache + mysql. My Vagrant VM ip: 192.168.11.11, local machine hosts points to192.168.11.11 reactphp.dev, and it works.
And, I'm using this code: https://github.com/muuknl/phprealtimechat to test websocket.
Then I visitreactphp.devin my Chrome browser, and I start server script using:php bin/server.php, and after I type in the username I just got the error:
WebSocket connection to 'ws://192.168.11.11:2000/' failed: Error in connection establishment: net::ERR_CONNECTION_TIMED_OUT
It works well when I changed the websocket ip to
`ws://127.0.0.1:2000/', but why it does not work if I change to my VM's