0

When I run a Docker container, I know that if I bind volume foo:bar, the contents of foo on the host will show in bar in the container. However, the --mount option of the RUN command in a Dockerfile does not work the same way. I don't care about the excuse of portable containers, during the execution of the Dockerfile I need to reference an exact volume in the host so that yum will work correctly for what I need it to do. How do I do that?

1 Answers1

0

I figured out how to do this without jumping a gazillion hoops. I ran the container with -v to mount the folder into the container, then exited the container and committed to a new one. Now I have a container I can work with that has the mount already done.