Git Product home page Git Product logo

ansible-lxc-ssh's Issues

LXD support and evolution?

LXD support seems easy: just replace s/lxc-attach --name /lxc exec /

but there are some issues arising for some module like user or file transfer (lxc file push/pull).

Any plan for evolution?

Thanks

No module named six

no matter if I install it with:

apt-get install python-six

or

pip install six

I get the error message in title.

incompatibility with ansible v2.2: NameError: global name 'BOOLEANS' is not defined

$ ansible -i inventory dltest -m apt -a "name=wget state=present" -vvvv
Loading callback plugin minimal of type stdout, v2.0 from /usr/local/lib/python2.7/dist-packages/ansible/plugins/callback/__init__.pyc
Using module file /usr/local/lib/python2.7/dist-packages/ansible/modules/core/packaging/os/apt.py
XXX exec_command: /bin/sh -c '( umask 77 && mkdir -p "` echo $HOME/.ansible/tmp/ansible-tmp-1478807384.4-192196860889135 `" && echo ansible-tmp-1478807384.4-192196860889135="` echo $HOME/.ansible/tmp/ansible-tmp-1478807384.4-192196860889135 `" ) && sleep 0'
XXX connect
[DEPRECATION WARNING]: ansible.utils.unicode.to_bytes is deprecated.  Use ansible.module_utils._text.to_bytes instead.
This feature will be removed in version 2.4. 
Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
[DEPRECATION WARNING]: ansible.utils.unicode.to_unicode is deprecated.  Use ansible.module_utils._text.to_text instead.
This feature will be removed in version 2.4. 
Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
<x.y.z.109> SSH: EXEC ssh -C -vvv -o ForwardAgent=yes -o 'IdentityFile="/home/user/.ssh/keys/key-201511"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=10 -tt x.y.z.109 'lxc exec dltest -- /bin/sh -c '"'"'/bin/sh -c '"'"'"'"'"'"'"'"'( umask 77 && mkdir -p "` echo $HOME/.ansible/tmp/ansible-tmp-1478807384.4-192196860889135 `" && echo ansible-tmp-1478807384.4-192196860889135="` echo $HOME/.ansible/tmp/ansible-tmp-1478807384.4-192196860889135 `" ) && sleep 0'"'"'"'"'"'"'"'"''"'"''
XXX connect
<x.y.z.109> PUT /tmp/tmpy2jk8V TO /root/.ansible/tmp/ansible-tmp-1478807384.4-192196860889135/apt.py
XXX close
An exception occurred during task execution. The full traceback is:
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/ansible/executor/task_executor.py", line 119, in run
    res = self._execute()
  File "/usr/local/lib/python2.7/dist-packages/ansible/executor/task_executor.py", line 490, in _execute
    result = self._handler.run(task_vars=variables)
  File "/usr/local/lib/python2.7/dist-packages/ansible/plugins/action/normal.py", line 33, in run
    results = merge_hash(results, self._execute_module(tmp=tmp, task_vars=task_vars))
  File "/usr/local/lib/python2.7/dist-packages/ansible/plugins/action/__init__.py", line 593, in _execute_module
    self._transfer_data(remote_module_path, module_data)
  File "/usr/local/lib/python2.7/dist-packages/ansible/plugins/action/__init__.py", line 299, in _transfer_data
    self._transfer_file(afile, remote_path)
  File "/usr/local/lib/python2.7/dist-packages/ansible/plugins/action/__init__.py", line 276, in _transfer_file
    self._connection.put_file(local_path, remote_path)
  File "/opt/tmp/vagrant/homelab/ansible-lxc-ssh/lxc_ssh.py", line 564, in put_file
    if scp_if_ssh in BOOLEANS:
NameError: global name 'BOOLEANS' is not defined

dltest | FAILED! => {
    "failed": true, 
    "msg": "Unexpected failure during module execution.", 
    "stdout": ""
}

Any plans to make this compatible with latest Ansible 2.4.x?

from ansible.compat.six can't be found in latest Ansible, resulting in an error when using the plugin.

Looks like your connection plugin is the only one that enables ssh-less management of remote lxc containers. The Openstack one is unusable for some reason and there's zero documentation and the official lxc plugin doesn't support remote lxc containers.

Cheers

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.