Speed up ansible facts gathering

Restrict network from gathering of unrelated facts.
That can be slow on systems with complex network configurations.

Change-Id: Iae527bbb03d01e38a6a59c61f294a3b294ffa0df
Signed-off-by: Bogdan Dobrelya <bdobreli@redhat.com>
This commit is contained in:
Bogdan Dobrelya 2020-10-08 16:29:38 +02:00
parent 0ffabb4fe3
commit 473db72e89
2 changed files with 5 additions and 1 deletions

View File

@ -616,6 +616,7 @@ outputs:
setup:
gather_subset:
- '!all'
- '!min'
- 'hardware'
when: swift_raw_disks
- name: Mount devices defined in SwiftRawDisks

View File

@ -104,7 +104,10 @@ outputs:
upgrade_tasks:
- name: Gather missing facts
setup:
gather_subset: "distribution"
gather_subset:
- '!all'
- '!min'
- 'distribution'
when: >-
ansible_facts['distribution'] is not defined or
ansible_facts['distribution_major_version'] is not defined