Install the APM Insight .NET agent on Docker Containers
Installing the .NET agent in a Docker container is the same as installing the standard .NET agent in Windows. You need to configure the DockerFile to perform the installation.
Install the .NET agent on a Windows Docker container
Below is an example of configuring the .NET agent on a Windows Docker container.
FROM mcr.microsoft.com/dotnet/framework/aspnet
# Publish your application
COPY your app to be published /inetpub/wwwroot
# Download the APM Insight .NET agent installer
RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12;\
Invoke-WebRequest "https://staticdownloads.site24x7.com/apminsight/agents/apminsight-dotnetagent.msi" -UseBasicParsing -OutFile "apminsight-dotnetagent.msi"
# Install the APM Insight .NET agent
RUN Start-Process -Wait -FilePath msiexec -ArgumentList /i, "apminsight-dotnetagent.msi", /qn, editconfig=false, useappfilters=false, license.key=YOUR_LICENSE_KEY
# Remove the APM Insight .NET agent installer
RUN Remove-Item "apminsight-dotnetagent.msi"
# Set your application name
ENV SITE24X7_APP_NAME=YOUR_APP_NAME
Install the .NET agent on a Linux Docker container
Get information on configuring the .NET agent on a Linux Docker container.
Related articles
How to install various APM Insight agents in a Docker container
Java | PHP | Node.js | Python
How to install various APM Insight agents in a Kubernetes environment
Java | .NET | PHP | Node.js | Python