My local machine is a Linux Mint Tricia including Docker and Visual Studio Code.
I start a docker container by this command.
$ 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
My purpose is to debug a code of '/home/evan/Projects' that work on tensorflow with docker.
My assumption is to attach debug to bash on this container ('for_study'), but I have no idea how to attach.
What I tried:
I use Visual Studio Code.
- using plugin: Docker 1.1.0
- using plugin: Remote-Containers 0.117.0
launch.json
{
"version": "0.2.0",
"configurations": [
{
"name": "Python: Attach using Process Id",
"type": "python",
"request": "attach",
"processId": "${command:pickProcess}"
}
]
}
Sorry, I'm docker beginner.
If PyCharm Pro is easier, I will buy it.
Thanks.
