Deploy rack app to fargate code#
![deploy rack app to fargate deploy rack app to fargate](https://miro.medium.com/max/1104/1*VBXyLN-ZYrpRIfmQp_dcnw.jpeg)
![deploy rack app to fargate deploy rack app to fargate](https://miro.medium.com/max/2000/0*jMeXEIY9PWxNo9uW.png)
Note: You must create a volume before creating container definitions in order to set the shared volume in each container. Add a volume of type Bind Mount named oneagent. Name the task, optionally set roles and sizes, then scroll down to Volumes > Add volume. Go to Fargate Task Definition > Create New Task Definition > select Fargate > click Next Step. One is for downloading and unzipping the OneAgent to a shared volume, the other is your application container, which must mount the same volume.įor the runtime injection, follow the steps below.
Deploy rack app to fargate install#
To install Dynatrace OneAgent at runtime, you must deploy your application using a task with two container definitions.
![deploy rack app to fargate deploy rack app to fargate](https://res.cloudinary.com/practicaldev/image/fetch/s--ZD3zqSGV--/c_imagga_scale,f_auto,fl_progressive,h_900,q_auto,w_1600/https://dev-to-uploads.s3.amazonaws.com/i/2kpp7zjrrsqms96yw6n0.png)
![deploy rack app to fargate deploy rack app to fargate](https://d2908q01vomqb2.cloudfront.net/1b6453892473a467d07372d45eb05abc2031647a/2018/01/26/Slide5.png)
Unzip -d " $DT_HOME" " $DT_HOME/oneagent.zip" & \ĮNTRYPOINT ĬMD # the command of your application, for example, Java Wget -O " $DT_HOME/oneagent.zip" " $DT_API_URL/v1/deployment/installer/agent/unix/paas/latest?Api-Token= $DT_API_TOKEN& $DT_ONEAGENT_OPTIONS" & \ It defaults to the Dynatrace environment API configured on the API URL of OneAgentAPM.īash copy download ARG DT_API_URL= " ARG DT_API_TOKEN= ""ĪRG DT_ONEAGENT_OPTIONS= "flavor=default&include=&include=" If set, it indicates the URL from where the OneAgent app-only package will be downloaded. It defaults to "/opt/dynatrace/oneagent-paas". If set, it indicates the path where the unpacked OneAgent directory will be mounted. If set, it filters which code modules are to be downloaded. Note: If your container uses musl (for example, Alpine base image), you must add the flavor annotation in order to monitor it. If set, it indicates whether binaries for glibc or musl are to be downloaded. If not set, the default on the namespace is used. If set to false, no modifications will be applied to the pod.