Docker (Linux)
  • 09 Oct 2019
  • 1 Minute To Read
  • Contributors
  • Print
  • Share
  • Dark

Docker (Linux)

  • Print
  • Share
  • Dark

This document details how to install the .Net Core APM Profiler in your .Net Core application running on Docker or Docker Swarm.


Follow the Retrace Docker Install Guide.

.Net Core Docker Setup

Dockerfile Configuration

Adjust your Dockerfile to include the .Net Core Profiler:

RUN mkdir -m 0755 -p /stackify-dotnet-apm && \
    cd /stackify-dotnet-apm && \
    wget && \
    tar -zxvf stackify-dotnet-apm-install-linux-latest.tar.gz && \
    cd stackify-dotnet-apm-install-linux && \
    ./ --docker && \
    cd .. && \
    rm -rf stackify-dotnet-apm-install-linux && \
    rm stackify-dotnet-apm-install-linux-latest.tar.gz

ENV CORECLR_PROFILER={cf0d821e-299b-5307-a3d8-b283c03916da}
ENV CORECLR_PROFILER_PATH="/stackify-dotnet-apm/"

Name Your Application

Create a file named Stackify.json and copy it to your container in the same folder as your application.

    "AppName": "MyApp",
    "Environment": "Production"

Running your Application

Start your application with the stackify shared volume.

docker run -v stackify:/usr/local/stackify [your-application-image] 


Make application requests, you can then verify results in the Retrace dashboard.

Was This Article Helpful?