How to mount a host directory in a Docker container

后端 未结 25 1607
庸人自扰
庸人自扰 2020-11-22 12:43

I am trying to mount a host directory into a Docker container so that any updates done on the host is reflected into the Docker containers.

Where am I doing somethin

25条回答
  •  一生所求
    2020-11-22 13:14

    Note that in Windows you'll have to provide the absolute path.

    • Host: Windows 10
    • Container: Tensorflow Notebook

    Below worked for me.

    docker run -t -i -v D:/projects/:/home/chankeypathak/work -p 8888:8888 jupyter/tensorflow-notebook /bin/bash
    

提交回复
热议问题