加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
run_docker_jupyter_windows.cmd 1.17 KB
一键复制 编辑 原始数据 按行查看 历史
REM
REM Attention: Windows Toolbox users - you MUST put the course repo in C:\Users\%username\mlcourse.ai
REM Attention: Use Ctrl-C to shut down. If you close the window, the container may still be running.
REM
SET IMAGE="festline/mlcourse_ai"
REM check for new versin of the image
docker pull %IMAGE%
IF DEFINED DOCKER_TOOLBOX_INSTALL_PATH (
FOR /F "tokens=* USEBACKQ" %%a in (`"docker-machine ip default"`) DO SET JUP_IP=%%a
)
IF DEFINED DOCKER_TOOLBOX_INSTALL_PATH (
docker run -it -d --name mlcourse_ai --rm -u 1000:1000 -v /c/Users/%username%/mlcourse.ai:/notebooks -w /notebooks -e HOME=/notebooks/home -p 4545:8888 %IMAGE% jupyter-notebook --NotebookApp.ip=0.0.0.0 --NotebookApp.password_required=False --NotebookApp.token='' --NotebookApp.custom_display_url=http://%JUP_IP%:4545 & explorer "http://%JUP_IP%:4545" & docker attach mlcourse_ai
) ELSE (
docker run -it --rm -u 1000:1000 -v %cd%:/notebooks -w /notebooks -e HOME=/notebooks/home -p 4545:8888 -e JUPYTER_RUNTIME_DIR=/tmp -e JUPYTER_DATA_DIR=./ %IMAGE% jupyter-notebook --NotebookApp.ip=0.0.0.0 --NotebookApp.password_required=False --NotebookApp.token='' --NotebookApp.custom_display_url="http://localhost:4545"
)
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化