Unable to retrieve cyberark password using lookup('community.general.cyberarkpassword', cyquery)

Unable to retrieve cyberark password using lookup(‘community.general.cyberarkpassword’, cyquery).

  • I have created a simple playbook to fetch the password from ansible tower
---

- name: Gather system info
  hosts: all
  connection: local

  collections:
    - paloaltonetworks.panos

  vars:
    device:
      ip_address: "{{ inventory_hostname }}"
      username: "MYUSERID"
      password: "{{ lookup('community.general.cyberarkpassword', cyquery)[0]['password'] }}"
    cyquery:
      appid: 'MYAPPID'
      query: 'Safe=SAFE_ID;Folder=Root;UserName=MYUSERID'
      output: 'Password'

  tasks:
    - name: Gather facts for device
      paloaltonetworks.panos.panos_facts:
        provider: "{{ device }}"
  • This code does work on the server but not using ansible tower
  • I did set the following under Job settings under Paths to expose to isolated jobs
[
  "/opt/CARKaim/sdk/:/opt/CARKaim/sdk:O",
  "/opt/CARKaim/sdk/clipasswordsdk/:/opt/CARKaim/sdk/clipasswordsdk:O"
]