Fix the color when unreachable in default cb plugin
The dedicated color for unreachable errors was not being used in the default cb plugin. This corrects the color.
This commit is contained in:
parent
f3b9449e07
commit
ed457ad53b
1 changed files with 2 additions and 2 deletions
|
@ -103,9 +103,9 @@ class CallbackModule(CallbackBase):
|
||||||
def v2_runner_on_unreachable(self, result):
|
def v2_runner_on_unreachable(self, result):
|
||||||
delegated_vars = result._result.get('_ansible_delegated_vars', None)
|
delegated_vars = result._result.get('_ansible_delegated_vars', None)
|
||||||
if delegated_vars:
|
if delegated_vars:
|
||||||
self._display.display("fatal: [%s -> %s]: UNREACHABLE! => %s" % (result._host.get_name(), delegated_vars['ansible_host'], self._dump_results(result._result)), color=C.COLOR_ERROR)
|
self._display.display("fatal: [%s -> %s]: UNREACHABLE! => %s" % (result._host.get_name(), delegated_vars['ansible_host'], self._dump_results(result._result)), color=C.COLOR_UNREACHABLE)
|
||||||
else:
|
else:
|
||||||
self._display.display("fatal: [%s]: UNREACHABLE! => %s" % (result._host.get_name(), self._dump_results(result._result)), color=C.COLOR_ERROR)
|
self._display.display("fatal: [%s]: UNREACHABLE! => %s" % (result._host.get_name(), self._dump_results(result._result)), color=C.COLOR_UNREACHABLE)
|
||||||
|
|
||||||
def v2_playbook_on_no_hosts_matched(self):
|
def v2_playbook_on_no_hosts_matched(self):
|
||||||
self._display.display("skipping: no hosts matched", color=C.COLOR_SKIP)
|
self._display.display("skipping: no hosts matched", color=C.COLOR_SKIP)
|
||||||
|
|
Loading…
Reference in a new issue