Developing on pycharm with a chroot environment?

486 views Asked by At

I have an Arch Linux Machine inside which I have "containers" like Centos which I normally chroot and work upon from the command line. I setup Pycharm to work on a project that is inside this "container" The "container" was created using LXC, but I normally login using chroot.

There is a problem running the interactive debugger from Pycharm however.

The command that is run to start the interactive debugger from Pycharm is:

/usr/lib/lxc/centos/rootfs/home/virtual-environment/usr/bin/python /home/nishant/packages/pycharm-community/helpers/pydev/pydevconsole.py

ERROR:root:code for hash md5 was not found

I was able to reproduce this problem without Pycharm.

If I chroot to that environment and then do usr/bin/ python -v -c "import hashlib" everything works.

If I execute /usr/lib/lxc/centos/rootfs/home/virtual-environment/usr/bin/python from my main system, the same error comes.

Fundamentally I think the problem is that I am executing the command in a wrong environment. I think Pycharm should not be executing this interpreter directly but instead in a chroot context.

  1. Is it possible to achieve that using Pycharm?
  2. In general, is it possible to execute a chroot command by not doing a chroot, like setting the LDD path differently or something like that?
0

There are 0 answers