If you are using Agent v6, Datadog recommends that you upgrade to Agent v7. Agent v7 only includes support for Python 3.
However, there may be a case where you wish to continue using Agent v6 while updating to Python 3. Starting with Datadog Agent v6.14.0, Agent v6 integrates both Python 2 and Python 3 runtimes. This means that Agent Checks can be run either with Python 2 or Python 3, depending on the Agent configuration.
Alternatively, specify which Python runtime you want to use by setting the DD_PYTHON_VERSION environment variable to 2 or 3. Environment variables take precedence over configuration options in datadog.yaml. For example, by setting the DD_PYTHON_VERSION environment variable, the python_version option in datadog.yaml is ignored.
This is an Agent-wide configuration option. All Python checks launched by an Agent use the same Python runtime.
By default, the Datadog Helm chart uses the Agent 7 image that embeds the Python 3 runtime.
To keep the Datadog Agent updated, edit your datadog-values.yaml to remove any information under the agent.image and the clusterChecksRunner.image sections.
To use a specific container registry, set it with agent.image.repository and clusterChecksRunner.image.repository. Ensure that agents.image.tag and clusterChecksRunner.image.tag are undefined.
To set the Agent to a specific version, set agents.image.tag and clusterChecksRunner.image.tag. All image tags starting with 7.* embed the Python 3 runtime.
Note: Datadog recommends that you do not set the *.image.tag. Instead, let the Datadog Operator keep the Agent image tag up-to-date with an Agent 7 image.
If you need to use an Agent JMX image, you can set it without specifying the Agent *.image.tag: