You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
2. Copy the Datadog .NET tracer into your Docker image.
23
+
2. Copy the Datadog .NET tracer into your Docker image. If the GitHub requests made by the script are rate limited, pass a GitHub token saved in the environment variable
24
+
`GITHUB_TOKEN` as a [Docker build secret][2]`--secret id=github-token,env=GITHUB_TOKEN`.
23
25
For linux/amd64, include the following:
24
26
```dockerfile
25
-
RUN chmod +x /app/dotnet.sh && /app/dotnet.sh
27
+
RUN --mount=type=secret,id=github-token,env=GITHUB_TOKEN \
28
+
chmod +x /app/dotnet.sh && /app/dotnet.sh
26
29
```
27
30
28
31
For other architecture types, configure your Dockerfile like so:
@@ -60,7 +63,8 @@ If you already have an entrypoint defined inside your Dockerfile, you can instea
60
63
```dockerfile
61
64
# For alpine or arm64 builds, refer to tracer installation of the explanation section
62
65
COPY --from=datadog/serverless-init:1 / /app/
63
-
RUN chmod +x /app/dotnet.sh && /app/dotnet.sh
66
+
RUN --mount=type=secret,id=github-token,env=GITHUB_TOKEN \
67
+
chmod +x /app/dotnet.sh && /app/dotnet.sh
64
68
65
69
ENV DD_SERVICE=datadog-demo-run-dotnet
66
70
ENV DD_ENV=datadog-demo
@@ -73,7 +77,8 @@ If you require your entrypoint to be instrumented as well, you can swap your ent
73
77
```dockerfile
74
78
# For alpine or arm64 builds, refer to tracer installation of the explanation section
75
79
COPY --from=datadog/serverless-init:1 / /app/
76
-
RUN chmod +x /app/dotnet.sh && /app/dotnet.sh
80
+
RUN --mount=type=secret,id=github-token,env=GITHUB_TOKEN \
0 commit comments