Articles → DOCKER → Mount A Volume To The Docker Container

Mount A Volume To The Docker Container

Purpose Of Mounting A Volume


docker run -d   --name=<container name> --mount source=<volume>,destination=<path inside container> <image name>

Picture showing the command to mount the volume in docker
Click to Enlarge

Check If The Volume Is Mounted Correctly

docker inspect <container name>

Picture showing the Mounts attribute inside the container
Click to Enlarge

Posted By  -  Karan Gupta
Posted On  -  Sunday, May 28, 2023


Your Email Id  
Query/FeedbackCharacters remaining 250