1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

hashi_vault: fix token logic again (#27863)

The token is not mandatory, and there are more ways of setting it than
passing it in as a module arg.
This commit is contained in:
flowerysong 2017-08-09 10:53:30 -04:00 committed by Ryan Brown
parent 767cd82e42
commit e2b2ba6bc7

View file

@ -68,10 +68,6 @@ class HashiVault:
self.url = kwargs.get('url', ANSIBLE_HASHI_VAULT_ADDR)
self.token = kwargs.get('token')
if self.token is None:
raise AnsibleError("No Hashicorp Vault Token specified for hash_vault lookup")
# split secret arg, which has format 'secret/hello:value' into secret='secret/hello' and secret_field='value'
s = kwargs.get('secret')
if s is None: