reactphp / reactphp

Event-driven, non-blocking I/O with PHP.

Home Page:https://reactphp.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Non-availability outside docker container

gossoudarev opened this issue · comments

Unlike nodejs process, PHP React HTTP listens to something that doesn't allow localhost to be seen outside the container.
What to do? See netstat comparison of ReactPHP and Nodejs

node-php

This is actually a Socket feature and it works as expected and documented :-)

If you want to listen on all or some public interfaces, you have to specify which address your server socket is listening on like this:

$server = new Server('[::]:80', $loop);

See https://github.com/reactphp/socket#server for more details.

I hope this helps 👍