Community.general.lxc_container is senescent

Hello,

The ansible module which appears to be meant to manage lxc containers is inoperable, and refers to the archived lxc/python2-lxc library.

lxc_container is in the latest ansible-galaxy community.general documentation, but is missing - probably because it cannot be built. Which is pretty disappointing.

The vagrant infrastructure for the lxc provider is a bit creaky too. Seems to work, but there are no official Ubuntu 20.04 LTS boxes.

Is it me, or the ecosystem, that is missing something?

Cheers…

I thought that Ansible transitioned to python3 by now, in which case it should be using python3-lxc that in general is in a much better state than python2-lxc.

I was expecting a python3 version. I can find no such animal.
I expect that will turn off quite few dev-ops people from using lxc
:frowning:

Seems to be here

Yes that is the prerequisite which @stgraber keeps up-to-date.
The ansible module 'Community.general.lxc container needs to be rebuilt to use it.

I cant see any link to the ansible module source from the referenced documentation.

I can see some source with the author mentioned in the docs (Kevin Carter) here:

gitlab lxc_container.py

Hello!

Could you please tell me, did you solve a problem with module community.general.lxc_container. I also have a problem with this. My playbook does not work.

- hosts: devel-lxd01
  become: true

  tasks:

    - name: Create a started container
      community.general.lxc_container:
        name: test-container-started
        container_log: true
        template: ubuntu
        state: started
        template_options: --release trusty

I am getting error:
TASK [Create a started container] *************************************************************************************************************
fatal: [devel-lxd01]: FAILED! => {“changed”: false, “msg”: “Failed to find required executable “lxc-create” in paths: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin”}

PLAY RECAP ************************************************************************************************************************************
devel-lxd01                : ok=1    changed=0    unreachable=0    failed=1    skipped=0    rescued=0    ignored=0