From 7778aca966064a0a97879178b1829047151c05b3 Mon Sep 17 00:00:00 2001 From: Brian Coca Date: Tue, 11 Mar 2014 21:30:58 -0400 Subject: [PATCH] templates ignore_errors --- lib/ansible/playbook/__init__.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/ansible/playbook/__init__.py b/lib/ansible/playbook/__init__.py index 6596552625..918b934171 100644 --- a/lib/ansible/playbook/__init__.py +++ b/lib/ansible/playbook/__init__.py @@ -402,6 +402,10 @@ class PlayBook(object): ansible.callbacks.set_task(self.runner_callbacks, None) return True + # template ignore_errors + cond = template(play.basedir, task.ignore_errors, task.module_vars, expand_lists=False) + task.ignore_errors = utils.check_conditional(cond , play.basedir, task.module_vars, fail_on_undefined=C.DEFAULT_UNDEFINED_VAR_BEHAVIOR) + # load up an appropriate ansible runner to run the task in parallel results = self._run_task_internal(task)