how can I assign a custom image to a particular container running a particular app?
search cancel

how can I assign a custom image to a particular container running a particular app?

book

Article ID: 277058

calendar_today

Updated On:

Products

CA Application Performance Management SaaS

Issue/Introduction

I can build an image for a tools.jar using the follow steps:
 
#Base docker image for custom jdk tools.jar
FROM alpine:latest
#COPY the custom jdk tools.jar path appended with customJdkTools/vendor/vmName/version/tools.jar to the path “/opt/caapm/agent”
COPY ./customJdkTools /opt/caapm/agent
# Dummy CMD to active the container

CMD ["tail","-f","/dev/null"]

 
But how can I assign this image to a particular container running a particular app?
 

Resolution

Containers run from images so this image cannot be attached to a running container but will run as a standalone container. You cannot assign a container/image to an already running container.