我的本地计算机是Linux Mint Tricia,包括Docker和Visual Studio Code。
我通过此命令启动Docker容器。
$ docker run -it --name for_study -p 8888:8888 --mount type=bind,src=/home/evan/Projects,dst=/projects --gpus all tensorflow/tensorflow:1.14.0-gpu-py3
我的目的是调试可在docker上使用tensorflow的代码'/ home / evan / Projects'。>>
我的假设是将调试附加到此容器上的bash('for_study'),但我不知道如何附加。
我尝试过的事情:
我使用Visual Studio Code。-使用插件:Docker 1.1.0-使用插件:Remote-Containers 0.117.0launch.json
{ "version": "0.2.0", "configurations": [ { "name": "Python: Attach using Process Id", "type": "python", "request": "attach", "processId": "${command:pickProcess}" } ] }
[抱歉,我是Docker初学者。如果PyCharm Pro更简单,我会购买。
谢谢。
我的本地计算机是Linux Mint Tricia,其中包括Docker和Visual Studio Code。我通过此命令启动Docker容器。 $ docker run -it --name for_study -p 8888:8888 --mount type = bind,src = / ...
已解决。