mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-24 11:21:25 -07:00
* Allow any_errors_fatal to be set in playbook. * Default to the config file value for any_errors_fatal only if it isn't already provided. * add _get_attr method
This commit is contained in:
parent
f3f0ba87ce
commit
aa658c64ec
2 changed files with 10 additions and 1 deletions
|
@ -21,6 +21,7 @@ __metaclass__ = type
|
|||
|
||||
import os
|
||||
|
||||
from ansible import constants as C
|
||||
from ansible.errors import AnsibleError, AnsibleParserError, AnsibleUndefinedVariable
|
||||
from ansible.module_utils.six import iteritems, string_types
|
||||
from ansible.module_utils._text import to_native
|
||||
|
@ -422,6 +423,14 @@ class Task(Base, Conditional, Taggable, Become):
|
|||
|
||||
return value
|
||||
|
||||
def _get_attr_any_errors_fatal(self):
|
||||
value = self._attributes['any_errors_fatal']
|
||||
if value is None:
|
||||
value = self._get_parent_attribute('any_errors_fatal')
|
||||
if value is None:
|
||||
value = C.ANY_ERRORS_FATAL
|
||||
return value
|
||||
|
||||
def _get_attr_environment(self):
|
||||
'''
|
||||
Override for the 'tags' getattr fetcher, used from Base.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue