# Deploy OneAgent on OpenShift for application-only monitoring

**URL:** <https://community.dynatrace.com/t/deploy-oneagent-on-openshift-for-application-only-monitoring/21151>\
**Category:** Container platforms\
**Tags:** openshift, kubernetes, docker\
**Created:** [June 27, 2019, 10:41am UTC](https://community.dynatrace.com/t/deploy-oneagent-on-openshift-for-application-only-monitoring/21151 "2019-06-27T10:41:03Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![refka\_hachani](https://avatars.discourse-cdn.com/v4/letter/r/e5b9ba/32.png) [@refka\_hachani](https://community.dynatrace.com/u/refka_hachani)\
**Post date:** [June 27, 2019, 10:41am UTC](https://community.dynatrace.com/t/deploy-oneagent-on-openshift-for-application-only-monitoring/21151/1 "2019-06-27T10:41:03Z")

</div>

Hello,

I’m trying to follow these instructions from [https://www.dynatrace.com/support/help/technology-support/cloud-platforms/openshift/installation-and-operation/application-only/deploy-oneagent-on-openshift-for-application-only-monitoring/](https://www.dynatrace.com/support/help/technology-support/cloud-platforms/openshift/installation-and-operation/application-only/deploy-oneagent-on-openshift-for-application-only-monitoring/) to deploy a OneAgent to monitor a Spring Boot application deployed under OpenShift Online 3.

First, I created a Docker file and inserted these instructions into it, replacing the environment ID, the token, the one agent option, and the command with the right variables.

ARG DT\_API\_URL=“https://\<environmentID\>.live.dynatrace.com/api” ARG DT\_API\_TOKEN=“\<token\>” ARG DT\_ONEAGENT\_OPTIONS=“flavor=default&include=\<technology1\>&include=\<technology2\>” ENV DT\_HOME=“/opt/dynatrace/oneagent” RUN mkdir -p “$DT\_HOME” && \ wget -O “$DT\_HOME/oneagent.zip” “$DT\_API\_URL/v1/deployment/installer/agent/unix/paas/latest?Api-Token=$DT\_API\_TOKEN&$DT\_ONEAGENT\_OPTIONS” && \ unzip -d “$DT\_HOME” “$DT\_HOME/oneagent.zip” && \ rm “$DT\_HOME/oneagent.zip” ENTRYPOINT [“/opt/dynatrace/oneagent/dynatrace-agent64.sh”] CMD [“executable”, “param1”, “param2”] # the command of your application, e.g. java

After that, I built the application image by executing the next command

oc new-build --binary --strategy=docker --allow-missing-images yourapp

However, it seems that isn’t working for me, as I’m getting the following error :

[root@CHBSLADT01TST LambdaAir]# oc new-build --binary --strategy=docker --allow-missing-images zuuloo

W0627 05:53:42.764249 1035 newapp.go:317] I Could not find an image stream match for “zuuloo.” Make sure that a Docker image with that tag is available on the node for the build to succeed.

\* A Docker build using binary input will be created

\* The resulting image will be pushed to the image stream “zuuloo: latest”

\* A binary build was created; use ‘start-build --from-dir’ to trigger a new build

--\> Creating resources with label build=zuuloo …

imagestream “zuuloo” created

error: buildconfigs “zuuloo” is forbidden: build strategy Docker is not allowed

--\> Failed

Has anyone experienced similar issues, and if you solved them, how did you do it?

Best,

[@Zbyszek C](https://answers.dynatrace.com/users/12707/view.html), @Daniela R. , I think that you are exposed to this issue. Could you help me, please?

Many thanks,

Refka

---

_[View the full topic](https://community.dynatrace.com/t/deploy-oneagent-on-openshift-for-application-only-monitoring/21151)._
