Hello,
i try to launch a 'docker-compose up' with the php:7.0-apache and i have this error
"Container command 'apache2-foreground' not found or does not exist."
I did not have this problem one week ago.
I have the same issue with latest docker version (Docker version 1.11.1, build 5604cbe) and container "jakubsacha/symfony-docker:php7-dev"
same problem here (Docker version 1.11.1, build 5604cbe)
I solved it!
the folder /var/www/ was mounted with an empty volume so the container won't start because of the inexistant workdir (defined as /var/www/html in Dockerfile)
I found out the same problem when mounting the /var/www folder, and it turned out to be the problem of workdir defined in Dockerfile. The log doesn't show the correct error message, I'm not sure if need a fix or not.
And this means, we can not mount folder /var/www anymore, the DocumentRoot should always be under /var/www/html. Should we delete the workdir in Dockerfile, because it's just at the end of the Dockerfile and doesn't really matter.
I cannot reproduce, so I think this may be an outdated bug: :heart:
$ docker pull php:7.0-apache
7.0-apache: Pulling from library/php
f49cf87b52c1: Already exists
185616061386: Already exists
4330d62fa9e0: Already exists
457292eacdcc: Already exists
1acf2a966b64: Already exists
c6c8840e3cd3: Already exists
0aa8917ee733: Already exists
3003eebbec26: Already exists
ad2353b7ccbd: Already exists
69676eb3c14a: Pull complete
7ec691592514: Pull complete
d50c9706358b: Pull complete
987c24b3dfe4: Pull complete
ed00fa6b923a: Pull complete
Digest: sha256:2f0c990c6a66c82f996e39e4f14cfe904d494b959137a90f4f93c2349523ebae
Status: Downloaded newer image for php:7.0-apache
$ docker run -it --rm php:7.0-apache
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.18.0.20. Set the 'ServerName' directive globally to suppress this message
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.18.0.20. Set the 'ServerName' directive globally to suppress this message
[Fri Dec 22 21:30:31.079802 2017] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.10 (Debian) PHP/7.0.26 configured -- resuming normal operations
[Fri Dec 22 21:30:31.079823 2017] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
Most helpful comment
I solved it!
the folder /var/www/ was mounted with an empty volume so the container won't start because of the inexistant workdir (defined as /var/www/html in Dockerfile)