Overview

In a Docker Linux container, use Single Step Instrumentation (SSI) for APM to install the Datadog Agent and instrument your applications in one step, with no additional configuration required.

Enable APM on your applications

To enable APM in a Docker Linux container:

  1. In the Datadog app, go to the Install the Datadog Agent on Docker page.

  2. In the Customize my agent install command section, go to Additional configuration > Application Observability, and turn on APM Instrumentation.

    The 'Customize your agent install command' section of in-app instructions for installing the Datadog Agent on Docker
  3. Copy and run the Agent installation command in your Docker container.

  4. Restart your applications.

Set SDK tracer versions

By default, Single Step Instrumentation installs the latest major versions of Datadog APM SDKs. Minor version updates are applied automatically when they become available.

You may want to customize SDK versions based on your application’s language version or specific environment requirements. You can control the major and minor versions used by customizing library versions during setup.

To customize tracer versions:

  1. In the Datadog app, go to the Install the Datadog Agent on Docker page.

  2. After you turn on APM Instrumentation, click Customize library versions.

    The 'Customize library versions' drop-down in the instructions for installing the Datadog Agent on Docker
  3. Find your language(s) and use the dropdown to either:

    • Pin an exact tracer version, or
    • Select the major version you want to use.
  4. Copy and run the updated installation command.

Available versions are listed in source repositories for each language:

Remove Single Step APM instrumentation from your Agent

If you don’t want to collect trace data for a particular service, host, VM, or container, complete the following steps:

Remove instrumentation for specific services

To remove APM instrumentation and stop sending traces from a specific service:

  1. Add the DD_INSTRUMENT_SERVICE_WITH_APM environment variable to the service startup command:
    docker run -e DD_INSTRUMENT_SERVICE_WITH_APM=false <service_start_command>
    
  2. Restart the service.

Remove APM for all services on the infrastructure

To stop producing traces, uninstall APM and restart the infrastructure:

  1. Run:
    dd-container-install --uninstall
    
  2. Restart Docker:
    systemctl restart docker
    
    Or use the equivalent for your environment.

Further reading

Additional helpful documentation, links, and articles: