I have the following
command: php -S localhost:4000 /app/index.php
Attaching to silextwig_silex-twig_1
That is normal. It is attaching to the
stdout of the container (for which there is no
stdout being logged). At this point, the container is running.
If you want to run in the background you would run with
docker-compose up -d instead of just
The actual HTTP request to port 3000 won't work because PHP is listening only on localhost. You need to modify your command to be
php -S 0.0.0.0:4000 /app/index.php so that it is listening on all IP addresses and can accept connections through the Docker NAT.