Sam's Notebook » one liner http://onsnetwork.org/kubu4 University of Washington - Fishery Sciences - Roberts Lab Thu, 08 Nov 2018 21:47:12 +0000 en-US hourly 1 http://wordpress.org/?v=4.0 Docker – One liner to create Docker container http://onsnetwork.org/kubu4/2016/06/09/docker-one-liner-to-create-docker-container/ http://onsnetwork.org/kubu4/2016/06/09/docker-one-liner-to-create-docker-container/#comments Thu, 09 Jun 2016 23:16:35 +0000 http://onsnetwork.org/kubu4/?p=2146

One liner to create Docker container for Jupyter notebook usage and data analysis on roadrunner (Xserve):

docker run -p 8888:8888 -v /Users/sam/gitrepos/LabDocs/jupyter_nbs/sam/:/notebooks -v /Users/sam/data/:/data -v /Users/sam/analysis/:/analysis -it kubu4/bioinformatics:v11 /bin/bash

This does the following:

  • Maps roadrunner port 8888 to Docker container port 8888 (for Jupyter notebook access outside of the Docker container)
  • Mounts my local Jupyter notebooks directory to the
    /notebooks

    directory in the Docker container

  • Mounts my local data directory to the
    /data

    directory in the Docker container

  • Mounts my local analysis directory to the
    /analysis

    directory in the Docker container

These commands allow me to interact with data outside of the Docker container.

]]>
http://onsnetwork.org/kubu4/2016/06/09/docker-one-liner-to-create-docker-container/feed/ 0