mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-26 22:51:23 -07:00
updated package to use minimal fact gathering
also fixed results handling of fact gathering
This commit is contained in:
parent
f07d6b26a7
commit
44bd1db976
1 changed files with 2 additions and 2 deletions
|
@ -46,9 +46,9 @@ class ActionModule(ActionBase):
|
||||||
pass # could not get it from template!
|
pass # could not get it from template!
|
||||||
|
|
||||||
if module == 'auto':
|
if module == 'auto':
|
||||||
facts = self._execute_module(module_name='setup', module_args=dict(filter='ansible_pkg_mgr'), task_vars=task_vars)
|
facts = self._execute_module(module_name='setup', module_args=dict(filter='ansible_pkg_mgr', gather_subset='!all'), task_vars=task_vars)
|
||||||
display.debug("Facts %s" % facts)
|
display.debug("Facts %s" % facts)
|
||||||
if 'failed' not in facts:
|
if 'ansible_facts' in facts and 'ansible_pkg_mgr' in facts['ansible_facts']:
|
||||||
module = getattr(facts['ansible_facts'], 'ansible_pkg_mgr', 'auto')
|
module = getattr(facts['ansible_facts'], 'ansible_pkg_mgr', 'auto')
|
||||||
|
|
||||||
if module != 'auto':
|
if module != 'auto':
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue