Dockerfile
For an on-premise server, also add the following keys to
Also, in above file, we used /etc/atatus-infra-agent/atatus.yml in the image:php-fpm as a service. But you can replace it with your process/service command.
In Docker, Atatus infra agent won’t start automatically. So you have to add the service atatus-infra-agent start before your process/service command either in ENTRYPOINT/CMD as follows.
Using ENTRYPOINT:
- Change
php-fpmto your start application command. - Update
ATATUS_RELEASEenvironment variable to latest version of the Atatus PHP agent. - Change the license key
lic_infra_***************.
Enable Logs
You can collect logs through infra agent by enablinglogs_enabled option.
In below Dockerfile, we have added the following
- Set
logs_enabledto true. - Copy sample
files.ymlto/etc/atatus-infra-agent/conf.d/files.d/folder. This file defines from which location/path to collect logs.
You can change the file path under
paths field.