diff options
Diffstat (limited to 'callback_plugins/openshift_quick_installer.py')
-rw-r--r-- | callback_plugins/openshift_quick_installer.py | 28 |
1 files changed, 6 insertions, 22 deletions
diff --git a/callback_plugins/openshift_quick_installer.py b/callback_plugins/openshift_quick_installer.py index fc9bfb899..b4c7edd38 100644 --- a/callback_plugins/openshift_quick_installer.py +++ b/callback_plugins/openshift_quick_installer.py @@ -36,30 +36,13 @@ What's different: """ from __future__ import (absolute_import, print_function) -import imp -import os import sys from ansible import constants as C +from ansible.plugins.callback import CallbackBase from ansible.utils.color import colorize, hostcolor -ANSIBLE_PATH = imp.find_module('ansible')[1] -DEFAULT_PATH = os.path.join(ANSIBLE_PATH, 'plugins/callback/default.py') -DEFAULT_MODULE = imp.load_source( - 'ansible.plugins.callback.default', - DEFAULT_PATH -) -try: - from ansible.plugins.callback import CallbackBase - BASECLASS = CallbackBase -except ImportError: # < ansible 2.1 - BASECLASS = DEFAULT_MODULE.CallbackModule - -reload(sys) -sys.setdefaultencoding('utf-8') - - -class CallbackModule(DEFAULT_MODULE.CallbackModule): +class CallbackModule(CallbackBase): """ Ansible callback plugin @@ -286,8 +269,9 @@ The only thing we change here is adding `log_only=True` to the self._display.display("", screen_only=True) # Some plays are conditional and won't run (such as load - # balancers) if they aren't required. Let the user know about - # this to avoid potential confusion. + # balancers) if they aren't required. Sometimes plays are + # conditionally included later in the run. Let the user know + # about this to avoid potential confusion. if self.plays_total_ran != self.plays_count: - print("Installation Complete: Note: Play count is an estimate and some were skipped because your install does not require them") + print("Installation Complete: Note: Play count is only an estimate, some plays may have been skipped or dynamically added") self._display.display("", screen_only=True) |