Put phpDaemon on Amazon EC2, Ubuntu system 14.04.

Here is the demon config:

user www-data; group www-data; max-workers 8; min-workers 1; start-workers 1; max-idle 0; path 'conf/AppResolver.php'; Pool:Servers\WebSocket { enable 1; listen 'tcp://0.0.0.0'; port 8047; } Pool:Servers\HTTP { enable 1; privileged; listen 'tcp://0.0.0.0'; port 8080; } \PHPDaemon\Examples\Example { enable 1; } \PHPDaemon\Examples\ExampleWebSocket { enable 1; } 

It seems to be a simple example. On the "Amazon" open ssh and http ports, that is, 22 and 80. When connected, it gives time out. Turned on all tcp-ports, the same probe.

How to solve this problem?

Link to phpDaemon: https://github.com/kakserpom/phpdaemon

  • if gnu / linux really stands there, then backslashes \ in it are interpreted not as path delimiters, but as escape characters . To separate the same parts of the path, this operating system uses a slash : / - aleksandr barakin
  • @alexanderbarakin, here it is rather not to indicate the path, but to search for a PHP class. Type "namespace Library \ Examples". Well, in the examples of the author indicated that way. - dustj
  • I pointed out the obvious, striking error, and how to deal with it, of course, is up to you. - aleksandr barakin
  • @alexanderbarakin, this is not an error, this is the namespace separator - etki
  • @Etki, if a program reading this file can “cope” with such escape sequences, this is good. - aleksandr barakin

1 answer 1

  1. you should make sure your program is running and, if necessary, run it. see conclusion:

     $ ps aux 
  2. make sure that it listens on the specified ports. see conclusion:

     $ sudo lsof -Pn -iTCP -sTCP:LISTEN 

    if you are not listening, you should analyze its logs - probably, the reason for “non-obedience” is indicated there.

  3. If you are running and listening, you should contact the technical support of the company that provided the hosting (in your case, as I understand it, amazon ).