Debug_with_docker_in_pycharm
Debug with docker in pycharm
Why
As I really really appreciate it that we can have a isolated
develop environment, when I heard pycharm
can debug with docker, I was more than happy. However, things are not that easy.
What I got
I tried, tried and tried. At an amzing monment I succeeded running docker on windows throgh DockerToolbox. Mostly, I refer One answer to Running a Docker image in PyCharm causes “Invalid volume specification”.(By the way, my machine and environment is exactly like the answer)
BUT suddenly I failed to repeat it.
So I changed to try it on ubuntu
Unbuntu 14.04 in virtualbox.
The default settings when add docker as shown below is not suitable for unbuntu 14.
According to another SO question's answer, adding unix:///var/run/docker.sock
to the API URL
shows Connection successful
when click Apply
. But when running programs it still won't work.
And then
Problem partially solved, when we use docker to debug our project throgh PyCharm, it's not attach
to a running docker and/or exec
the commands (by now). Instead it start a new Containner
and run the commands, so if we want to debug a python file, we should make sure the docker running python
when open.
In other word, the Dockerfile
better with last sentence:
CMD ["python3"]
And in linux (ubuntu) when this assured, all things is OK. And now I can debug with alpine-python
TODO
After succeeded in linux, I go back and try in windows, it's surely a bug of pycharm and hope can be solved in latter version.
And what's more, what I really want is more than this, I hope as below:
+------------------------------+
| | +------------------+ +-------------------+
| | <----------------+ | | |
| Docker/rkt/others | | Desktop UI XXXXXX Happy ME |
| +----------------> | | | |
| | +------------------+ +-------------------+
+------------------------------+
Some remote servers
In other word, no applications on PC/Desktop, no more reinstall systems, no different configurations, no more configurations problems
! But with full control of what we use.
I will review related techs in the future, and this is another weekend I spent play
with docker and all the configurations and DIT NOTHING WORTHFUL. Well, that's typical me. -.-
Debug_with_docker_in_pycharm的更多相关文章
随机推荐
- IP分片(IP Fragment)
为什么要分片 不同的链路类型能够支持的最大传输单元值(MTU: Maxitum Transmission Unit)主要是由相关RFC文档规定的,常见的以太网链路的MTU值为1500,如果需要转发的I ...
- Erlang ets -- something about cache continue
上一次说到了实现一个简单cache 的基本思路和想法, http://www.cnblogs.com/--00/p/erlang_ets_something_about_cache.html 在文末, ...
- 关于 android 环信无法正确获取昵称的问题
本案例中 username 记录成 userId了, nick 始终为空...,这是 getNick() 取得的就是 username..... 如果想自己取得自己系统的nickname则 做以下调整 ...
- <转--大话session>
大话Session 原文地址:http://www.cnblogs.com/shoru/archive/2010/02/19/1669395.html 结语 到这里,读者应该对session有了更多的 ...
- CCproxy 设置代理服务器。
CCproxy 设置代理服务器. 通过代理服务器上网,出口IP就固定成代理服务器的IP 设置安装比较简单,直接去ccproxy官网下载就行 如果服务器是公网服务器,记得在设置,高级里面的网络中,把禁止 ...
- CEP实时分析模型
大数据量的实时分析场景: 股票实时分析系统:大数据量(基于内存),要求分析汇总数据
- python值解析excel
原文:http://blog.csdn.net/tomatoandbeef/article/details/52253578 一.安装python和xlrd模块 python下载地址,安装好后要配置环 ...
- Mysql 索引概论
Mysql性能下降原因 JOIN连接过多 ,索引失效(单值,复合), 查询SQL过水, explian 语法分析SQL性能 https://blog.csdn.net/b1303110335/arti ...
- sql中合并列方法
方法一:创建合并列函数 -------创建一个方法---------- CREATE FUNCTION dbo.Role_Name(@AdminID int) ) AS BEGIN ) SET @r ...
- 转化RGB颜色为CMYK颜色
procedure RGBTOCMYK(R : byte; G : byte; B : byte; var C : byte; var M : byte; var Y : byte; var K : ...