piete...@gmail.com
unread,Aug 3, 2022, 6:14:54 AM8/3/22Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Ansible Development
Hi all,
I've written a lookup plugin that authenticates to some REST endpoint.
Once authenticated a token is returned that can be reused for further REST calls.
Is there a way I can store the token someplace, so that the next invocation
of the lookup plugin can access it and use it instead of authenticating with userid/pw
again ?
I tried to access the 'play' object to get its VariableManager, but I guess that's
not accessible from a LookupPlugin. Then I tried to use pythons' os.environ
to set a variable, but apparently each invocation of the lookup is done using
a different python instance, hence not sharing their environments.
Thanks for any help.
Pieter.