lxc / python3-lxc

Python 3.x binding for liblxc
https://linuxcontainers.org/lxc
GNU Lesser General Public License v2.1
57 stars 38 forks source link

Issues with Ansible lxc connection plugin #11

Closed pgauret closed 4 years ago

pgauret commented 5 years ago

I'm using Ansible's lxc connection plugin on Alpine Linux 3.9.3. I've had a couple of issues which seem to be related to the python3-lxc package used by Ansible's connection plugin.

  1. Ansible hangs when applying a playbook to an lxc container (and works fine on other hosts). Ansible issue and my initial attempt to troubleshoot at https://github.com/ansible/ansible/issues/54659

  2. Since upgrading to python 3.7 Ansible produces multiple RuntimeError: cannot release un-acquired lock messages when applying a playbook to an lxc container (and works fine on other hosts). Ansible issue and discussion pointing at python3-lxc at https://github.com/ansible/ansible/issues/55729

Zjemm commented 4 years ago

with the latest version of ansible i have a similar problem when i run a playbook with the lxc_container module it say's:

msg": "The lxc module is not importable. Check the requirements."

while in python itself (version 2.7 and 3.8) i can import the lxc module

stgraber commented 4 years ago

Sorry but it's not clear how this is a python3-lxc bug.

The error above suggests that the python3 version of the module is just plain missing on the system.

Yanonix commented 3 years ago

This bug is fixed in the fork https://github.com/CodeGra-de/python3-lxc/ by @libre-man I have merge this version 3.0.4 with the commit https://github.com/CodeGra-de/python3-lxc/commit/1c01bb9ce33a4e35cb53b3e3605654a3d1e6386c and it works. Could you consider merging it ?

stgraber commented 3 years ago

Would be great if @libre-man could open a PR to get those changes into this repo.

libre-man commented 3 years ago

Hi I'll take a look at creating a merge request. We've made also made some changes to our fork to suit the rest of our code better (e.g. to detect if attaching gets stuck) so it will take a few days until I have time to unravel it.

CyberCyclone commented 2 years ago

Would be great if @libre-man could open a PR to get those changes into this repo.

Did this end up getting merged. or fixed? If this hasn't been merged can we please re-open this issue. I'm facing the same issue.

sda399 commented 1 year ago

Would be nice to have an update on this, first it was closed as invalid ticket, then we discover there was a patch by @libre-man