How to connect PyCharm to a python interpreter located inside a Docker container?

前端 未结 10 2172
再見小時候
再見小時候 2021-01-30 03:40

I\'m starting with Docker, but I don\'t know how to configure PyCharm to use a python interpreter located in a container.

It was easy to setup with Vagrant, but there\'s

10条回答
  •  余生分开走
    2021-01-30 03:48

    You can get a bit crazy by installing Pycharm in the container and just running it from there. You'd have to do this by docker run -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=:0.0 pycharm-image but it should work just fine. But remember that all of Pycharm and your source would be in that container as well. So save, commit, and push early and often.

提交回复
热议问题