01 Dec 2023 08:37 AM - edited 01 Dec 2023 08:38 AM
PROBLEM
When you integrate OneAgent into your AWS Fargate or AWS App Runner application image, you encounter issues you want to investigate further.
SOLUTION
You can use the troubleshooting variable DT_LOGLEVELCON with the value INFO to see OneAgent logs in the CloudWatch logs. To use DT_LOGLEVELCON, do one of the following, depending on the integration and injection type.
DT_LOGLEVELCON environmental variable is defined and set to INFO on the container where OneAgent runs.AWS Fargate build-time injection or AWS App Runner build-time injection
Enter an additional line of code to the application image as in the example below:
COPY --from=<your-environment-url>/linux/oneagent-codemodules:<technology> / /
ENV LD_PRELOAD /opt/dynatrace/oneagent/agent/lib64/liboneagentproc.so
ENV DT_LOGLEVELCON INFOAWS Fargate runtime injection
Go to Environment > Environment variable and define DT_LOGLEVELCONwith the value INFO.