From 3d4838ac3352d431889d5224e000c53a5d1833af Mon Sep 17 00:00:00 2001 From: Spencer Krum Date: Mon, 17 Nov 2014 07:54:17 +0000 Subject: [PATCH] Turn off color in module install This ends up putting a bunch of ansi escapes in the apply test output. We could conditionally inject it form the apply test if people want color when this is run normally. Change-Id: I004bcd29671344430d271aad7f54186bc725215c --- install_modules.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/install_modules.sh b/install_modules.sh index 66288095c3..62569f10cf 100755 --- a/install_modules.sh +++ b/install_modules.sh @@ -60,7 +60,7 @@ if [ -z "${!MODULES[*]}" ] && [ -z "${!SOURCE_MODULES[*]}" ] ; then exit 0 fi -MODULE_LIST=`puppet module list` +MODULE_LIST=`puppet module list --color=false` # Transition away from old things if [ -d /etc/puppet/modules/vcsrepo/.git ]; then @@ -72,9 +72,9 @@ for MOD in ${!MODULES[*]} ; do # If the module at the current version does not exist upgrade or install it. if ! echo $MODULE_LIST | grep "$MOD ([^v]*v${MODULES[$MOD]}" >/dev/null 2>&1 ; then # Attempt module upgrade. If that fails try installing the module. - if ! puppet module upgrade $MOD --version ${MODULES[$MOD]} >/dev/null 2>&1 ; then + if ! puppet module upgrade $MOD --color=false --version ${MODULES[$MOD]} >/dev/null 2>&1 ; then # This will get run in cron, so silence non-error output - puppet module install $MOD --version ${MODULES[$MOD]} >/dev/null + puppet module install $MOD --color=false --version ${MODULES[$MOD]} >/dev/null fi fi done