Access php error logs in Docker
By default the container doesn't seem to log PHP errors to STDOUT or STDERR. I found that when using the php.ini-development
config file (see 'Configuration' in this article) it logs a lot more useful information.
To view the logs for a container, the most basic way is to do docker ps
, find the container hash, and then do docker logs container_hash
.
It exists the following docker command:
docker logs -f --details containerName
that will show you the mysql and php errors log files
for more check the documentation: docker logs