Java Agent Installation: Configure Docker Containers

Docker Support

Installation of the Stackify agent is required on the docker host system, it should not be installed on containers. See our guide to install the Linux agent here.

When installing the agent on the docker host add the  --docker argument to the installation script. This grants the agent access to view docker container stats:

wget --output-document=stackify.tar.gz && tar -zxvf stackify.tar.gz stackify-agent-install-32bit && cd stackify-agent-install-32bit && sudo ./ --docker --key "your_activation_key" --environment "your_environment_name"

Enabling APM for Docker Containers

To use APM on a docker container add the following arguments on container startup:

-v /usr/local/stackify:/usr/local/stackify --pid=host

Note: This creates a shared data volume between the docker host and containers at /usr/local/stackify and instructs docker to use unique pids across containers.

Example container run command:

docker run -it --pid=host -v /usr/local/stackify:/usr/local/stackify ubuntu bin/bash