Assume that I have a code repo. That code repo has the following files in it:
- Dockerfile
- test.sh
lets say I now build a docker image from the Dockerfile
docker build -t my-image .
Now I want to execute the test.sh in the context of my-image in a container, yet I don't have added test.sh to the docker image during build.
How do I run the docker image and execute the test.sh in it? Do I have to mount the repo as volume first or is there a quicker way?
Aucun commentaire:
Enregistrer un commentaire