Skip to content

Instantly share code, notes, and snippets.

@kosiara kosiara/HowTo.txt
Created Sep 22, 2015

Embed
What would you like to do?
Start Ubuntu docker image with a mounted directory
Prerequisite: Install docker
> docker version
Client:
Version: 1.8.2
API version: 1.20
Go version: go1.4.2
Git commit: 0a8c2e3
Built: Thu Sep 10 19:19:00 UTC 2015
OS/Arch: linux/amd64
#################
# list docker images to see if there is an ubuntu image
> docker images
REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE
ubuntu latest 91e54dfb1179 4 weeks ago 188.4 MB
# run ubuntu image to see if it is working properly
> docker run -t -i ubuntu /bin/bash
# type 'exit' to quit
# run ubuntu image with a mounted path
docker run -t -i -v /home/user/Music/shared_dir:/mnt ubuntu /bin/bash
----------------------------------------------
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.