Giter Site home page Giter Site logo

Comments (17)

TerryHowe avatar TerryHowe commented on July 28, 2024

what version of ansible-modules-hashivault do you have installed. I just tested with 2.1.1.0 and it is working for me:

hashivault $ ansible --version
ansible 2.1.1.0
  config file = /Users/THowe/crap/hashivault/ansible.cfg
  configured module search path = Default w/o overrides
hashivault $ ansible-playbook -v functional/test_status.yml 
Using /Users/THowe/crap/hashivault/ansible.cfg as config file

PLAY [localhost] ***************************************************************

TASK [setup] *******************************************************************
ok: [localhost]

TASK [hashivault_status] *******************************************************
ok: [localhost] => {"changed": false, "rc": 0, "status": {"n": 5, "progress": 0, "sealed": false, "t": 3}}

TASK [assert] ******************************************************************
ok: [localhost] => {"changed": false, "msg": "all assertions passed"}

TASK [assert] ******************************************************************
ok: [localhost] => {"changed": false, "msg": "all assertions passed"}

PLAY RECAP *********************************************************************
localhost                  : ok=4    changed=0    unreachable=0    failed=0   

hashivault $ pip list | grep ansible
DEPRECATION: The default format will switch to columns in the future. You can use --format=legacy (or define a list_format in your pip.conf) to disable this warning.
ansible (2.1.1.0)
ansible-modules-dcos (1.2.3)
ansible-modules-hashivault (2.5.6)
You are using pip version 9.0.0, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
hashivault $

from ansible-modules-hashivault.

mg03 avatar mg03 commented on July 28, 2024

pip search ansible-modules-hashivault | grep vault ansible-vault (1.0.4) - R/W an ansible-vault yaml file ansible-modules-hashivault (2.7.0) - Ansible Modules for Hashicorp Vault

and installed is

pip list | grep vault ansible-modules-hashivault (2.7.0)

from ansible-modules-hashivault.

mg03 avatar mg03 commented on July 28, 2024

Is there a specific setting to be set in ansible.cfg ?

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

No special setting in ansible.cfg, that ansible.cfg checked into the repo is what I use for functional testing

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

There was a change to the installation procedure that may be causing this. Could you try

pip uninstall ansible
pip install ansible

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

That might help if you upgraded from 2.5 or so to 2.7

from ansible-modules-hashivault.

mg03 avatar mg03 commented on July 28, 2024

I did not upgrade from 2.5 to 2.7. When I installed with pip I installed latest and 2.7 is the latest.

I can try to install 2.5.6 and see if that works. I can also uninstall and re-install ansible.

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

Don't install 2.5.6. I'll try again from a completely fresh venv.

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

You are running Python 2.7, right?

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

Thinking about this some more, you are targeting the qa hosts and that host doesn't have ansible-modules-hashivault installed. I guess to make that work, you'd need to install that or run your status on localhost

from ansible-modules-hashivault.

mg03 avatar mg03 commented on July 28, 2024

ansible-modules-hashivault have been installed on the remote host. Python 2.7, Ansible=2.1.1.0

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

Did that help at all?

from ansible-modules-hashivault.

mg03 avatar mg03 commented on July 28, 2024

Unfortunately, it did not. Same error.
{"failed": true, "msg": "Could not find imported module support code for hashivault_status. Looked for either * or hashivault"}

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

Well, I'm having a tough time because I can't reproduce this. What happens when you do this:

ls -last  ${VIRTUAL_ENV}/lib/python2.7/site-packages/ansible/modules/hashivault

from ansible-modules-hashivault.

mg03 avatar mg03 commented on July 28, 2024
/usr/local/lib/python2.7/dist-packages/ansible/modules/hashivault# ls -last
total 164
4 drwxr-sr-x 2 root staff 4096 Nov 21 04:21 .
4 -rw-r--r-- 1 root staff 2161 Nov 21 04:21 hashivault_policy_list.pyc
4 -rw-r--r-- 1 root staff 2336 Nov 21 04:21 hashivault_userpass_delete.pyc
4 -rw-r--r-- 1 root staff  164 Nov 21 04:21 __init__.pyc
4 -rw-r--r-- 1 root staff 2097 Nov 21 04:21 hashivault_audit_list.pyc
4 -rw-r--r-- 1 root staff 2521 Nov 21 04:21 hashivault_auth_enable.pyc
4 -rw-r--r-- 1 root staff 2137 Nov 21 04:21 hashivault_auth_list.pyc
4 -rw-r--r-- 1 root staff 2415 Nov 21 04:21 hashivault_policy_delete.pyc
4 -rw-r--r-- 1 root staff 2369 Nov 21 04:21 hashivault_policy_get.pyc
4 -rw-r--r-- 1 root staff 2355 Nov 21 04:21 hashivault_policy_set.pyc
4 -rw-r--r-- 1 root staff 3049 Nov 21 04:21 hashivault_read.pyc
4 -rw-r--r-- 1 root staff 2671 Nov 21 04:21 hashivault_secret_disable.pyc
4 -rw-r--r-- 1 root staff 2912 Nov 21 04:21 hashivault_secret_enable.pyc
4 -rw-r--r-- 1 root staff 2147 Nov 21 04:21 hashivault_secret_list.pyc
4 -rw-r--r-- 1 root staff 2287 Nov 21 04:21 hashivault_unseal.pyc
4 -rw-r--r-- 1 root staff 2736 Nov 21 04:21 hashivault_userpass_create.pyc
4 -rw-r--r-- 1 root staff 3018 Nov 21 04:21 hashivault_write.pyc
4 drwxr-sr-x 5 root staff 4096 Nov 21 04:21 ..
4 -rw-r--r-- 1 root staff 2674 Nov 21 04:21 hashivault_audit_enable.pyc
4 -rw-r--r-- 1 root staff 2111 Nov 21 04:21 hashivault_init.pyc
4 -rw-r--r-- 1 root staff 2136 Nov 21 04:21 hashivault_seal.pyc
4 -rw-r--r-- 1 root staff 2114 Nov 21 04:21 hashivault_status.pyc
4 -rw-r--r-- 1 root staff 2083 Oct 23 18:51 hashivault_secret_disable.py
4 -rw-r--r-- 1 root staff 2428 Oct 23 18:40 hashivault_secret_enable.py
4 -rw-r--r-- 1 root staff 1587 Oct 23 18:03 hashivault_secret_list.py
4 -rw-r--r-- 1 root staff 2170 Oct 14 13:17 hashivault_audit_enable.py
4 -rw-r--r-- 1 root staff 1539 Oct 14 13:17 hashivault_audit_list.py
4 -rw-r--r-- 1 root staff 1984 Oct 14 13:17 hashivault_auth_enable.py
4 -rw-r--r-- 1 root staff 1581 Oct 14 13:17 hashivault_auth_list.py
4 -rw-r--r-- 1 root staff 1589 Oct 14 13:17 hashivault_init.py
4 -rw-r--r-- 1 root staff 1829 Oct 14 13:17 hashivault_policy_delete.py
4 -rw-r--r-- 1 root staff 1791 Oct 14 13:17 hashivault_policy_get.py
4 -rw-r--r-- 1 root staff 1612 Oct 14 13:17 hashivault_policy_list.py
4 -rw-r--r-- 1 root staff 1802 Oct 14 13:17 hashivault_policy_set.py
4 -rw-r--r-- 1 root staff 2657 Oct 14 13:17 hashivault_read.py
4 -rw-r--r-- 1 root staff 1583 Oct 14 13:17 hashivault_seal.py
4 -rw-r--r-- 1 root staff 1576 Oct 14 13:17 hashivault_status.py
4 -rw-r--r-- 1 root staff 1702 Oct 14 13:17 hashivault_unseal.py
4 -rw-r--r-- 1 root staff 2198 Oct 14 13:17 hashivault_userpass_create.py
4 -rw-r--r-- 1 root staff 1746 Oct 14 13:17 hashivault_userpass_delete.py
4 -rw-r--r-- 1 root staff 2695 Oct 14 13:17 hashivault_write.py
0 -rw-r--r-- 1 root staff    0 Oct 14 13:17 __init__.py```

from ansible-modules-hashivault.

TerryHowe avatar TerryHowe commented on July 28, 2024

Cannot reproduce, reopen if still having issues. Maybe a fresh install of ansible would of helped here.

from ansible-modules-hashivault.

GeiserX avatar GeiserX commented on July 28, 2024

The same happened to me, in a fresh install of Ansible 2.7.6 with Python 2.7.12.
I even had to move the python module to the /usr/share/ansible/plugins/modules path by myself, because Ansible kept complaining about "module doesn't exist". I copied all of it but then this error occurred

from ansible-modules-hashivault.

Related Issues (20)

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.