# Docker PHP Error Logs

**URL:** <https://community.open-emr.org/t/docker-php-error-logs/11764>\
**Category:** Inpatient Development\
**Tags:** feature, infrastructure\
**Created:** [March 20, 2019, 7:35am UTC](https://community.open-emr.org/t/docker-php-error-logs/11764 "2019-03-20T07:35:10Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![adunsulag](https://community.open-emr.org/user_avatar/community.open-emr.org/adunsulag/32/12606_2.png) [@adunsulag](https://community.open-emr.org/u/adunsulag)\
**Post date:** [April 5, 2019, 3:52pm UTC](https://community.open-emr.org/t/docker-php-error-logs/11764/6 "2019-04-05T15:52:58Z")

</div>

@juggernautsei So this may not work if you are running a number of dockers at once, but for a single OpenEMR instance you can also just log into the docker instance. Its what I’m doing with the unit tests right now.

Here’s a paste of what I wrote for the unit testing tips:

First get your docker instance id for openemr

```auto
docker ps

```

That should give you a screen like so

```auto
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
9c214e0ce46c openemr/openemr:flex "./run_openemr.sh" 7 days ago Up 7 minutes 0.0.0.0:3000-3001->3000-3001/tcp, 0.0.0.0:8300->80/tcp, 0.0.0.0:9300->443/tcp openemr_openemr_1
272737bb9076 mariadb:10.2 "docker-entrypoint.s…" 9 days ago Up 7 minutes 0.0.0.0:8320->3306/tcp openemr_mysql_1
59865889c5ba phpmyadmin/phpmyadmin "/run.sh supervisord…" 9 days ago Up 7 minutes 9000/tcp, 0.0.0.0:8310->80/tcp    

```

Note the container id is the first line to the left of the openemr/openemr:flex Image column.  
Now execute the bash command against that container id.

```auto
sudo docker exec -i -t 9c214e0ce46c /bin/bash

```

Now you can monitor the log in the bash script that opened by running the tail command (everything after bash-4.4#).

```auto
bash-4.4# tail -f /var/log/apache2/error.log

```

---

_[View the full topic](https://community.open-emr.org/t/docker-php-error-logs/11764)._
