mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 20:01:25 -07:00
[PR #6839/e5dc6978 backport][stable-6] proxmox module utils: better error msg when token fails with old proxmoxer (#6845)
proxmox module utils: better error msg when token fails with old proxmoxer (#6839)
* proxmox module utils: clear msg when token fails with old proxmoxer
* add changelog frag
* better way to determine version
(cherry picked from commit e5dc697887
)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
parent
3405b24fa6
commit
d633f6c4c8
3 changed files with 6 additions and 0 deletions
|
@ -98,6 +98,8 @@ class ProxmoxAnsible(object):
|
|||
if api_password:
|
||||
auth_args['password'] = api_password
|
||||
else:
|
||||
if self.version() < LooseVersion('1.1.0'):
|
||||
self.module.fail_json('Using "token_name" and "token_value" require proxmoxer>=1.1.0')
|
||||
auth_args['token_name'] = api_token_id
|
||||
auth_args['token_value'] = api_token_secret
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue