Fix gather facts ignoring gather_subsets config (#59271)

* Fix gather facts ignoring gather_subsets config

 fixes #58728

* Update lib/ansible/playbook/play.py

Co-Authored-By: Abhijeet Kasurde <akasurde@redhat.com>
pull/59453/head
Brian Coca 5 years ago committed by GitHub
parent aa0de421d2
commit 8a886a6bee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -0,0 +1,2 @@
bugfixes:
- Gather facts should use gather_subset config by default.

@ -57,7 +57,7 @@ class Play(Base, Taggable, CollectionSearch):
# Facts
_gather_facts = FieldAttribute(isa='bool', default=None, always_post_validate=True)
_gather_subset = FieldAttribute(isa='list', default=None, listof=string_types, always_post_validate=True)
_gather_subset = FieldAttribute(isa='list', default=(lambda: C.DEFAULT_GATHER_SUBSET), listof=string_types, always_post_validate=True)
_gather_timeout = FieldAttribute(isa='int', default=C.DEFAULT_GATHER_TIMEOUT, always_post_validate=True)
_fact_path = FieldAttribute(isa='string', default=C.DEFAULT_FACT_PATH)

Loading…
Cancel
Save