rhel_facts module must use keyword arguments

The rhel_facts module must use keyword arguments.  The current
code gives this error:
```
Traceback (most recent call last):
...
  File "/tmp/ansible_ansible.posix.rhel_facts_payload_y10oy_4m/.../rhel_facts.py", line 72, in main
  TypeError: exit_json() takes 1 positional argument but 2 were given
```
The fix is to use all keyword arguments like other facts plugins.
This commit is contained in:
Rich Megginson 2023-03-23 15:52:16 -06:00
parent dc7ee92827
commit 583e4a6d6b

View file

@ -69,7 +69,7 @@ def main():
if os.path.exists("/run/ostree-booted"): if os.path.exists("/run/ostree-booted"):
ansible_facts['pkg_mgr'] = 'ansible.posix.rhel_rpm_ostree' ansible_facts['pkg_mgr'] = 'ansible.posix.rhel_rpm_ostree'
module.exit_json(ansible_facts, changed=False) module.exit_json(ansible_facts=ansible_facts, changed=False)
if __name__ == '__main__': if __name__ == '__main__':