From 12cb051ee59abe55fa61e572d70bd4f5bb078572 Mon Sep 17 00:00:00 2001 From: Tim Meusel Date: Thu, 5 Dec 2024 18:07:36 +0100 Subject: [PATCH] puppet_runonce: redirect stderr to stdout (#523) In case the Puppet Agent fails, it prints an error to stderr. Previously when running the task, and the agent failed, it would output only normal stdout, which contained only successful changes, and actual errors were hidden. --- tasks/puppet_runonce.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasks/puppet_runonce.sh b/tasks/puppet_runonce.sh index 1e72c86a6..c2cc59600 100755 --- a/tasks/puppet_runonce.sh +++ b/tasks/puppet_runonce.sh @@ -39,7 +39,7 @@ echo --detailed-exitcodes \ --color false \ $ENV_FLAG \ - $NOOP_FLAG + $NOOP_FLAG 2>&1 # Only exit non-zero if an error occurred. Changes (detailed exit code 2) are # not errors.