I am going through the official Ansible documentation regarding developing custom plugins. I am unable to find a way to access the variables declared in a playbook YML file from within the custom plugin (action). Is there a way to accomplish this task? I'd love to view a wiki page for the same (if it exists). TIA
For example:
1.) The playbook:
---
- hosts: all
tasks:
- name: "Set facts"
set_facts:
gate_enabled: "True"
2.) The plugin:
class ActionModule(ActionBase):
def run(self, tmp=None, task_vars=None):
#access the variable gate_enabled here