From 5a078e69d316f0ba60effeed0243bdf7f9935ef1 Mon Sep 17 00:00:00 2001 From: Alex Schultz Date: Fri, 2 Dec 2016 10:45:17 -0700 Subject: [PATCH] Fix puppet log move for non-root If you run something like all-in-one.sh as a non-root user, it will fail when it goes to move the puppet log file. We need to run it as sudo if the user is not root. Change-Id: I8b9d7e587f31a82fb4b59de770882139fd168667 --- functions | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions b/functions index 558cd18b6..fb14fee47 100644 --- a/functions +++ b/functions @@ -205,7 +205,7 @@ function catch_selinux_alerts() { } function timestamp_puppet_log() { - mv ${WORKSPACE}/puppet.log ${WORKSPACE}/puppet-$(date +%Y%m%d_%H%M%S).log + $SUDO mv ${WORKSPACE}/puppet.log ${WORKSPACE}/puppet-$(date +%Y%m%d_%H%M%S).log } function catch_puppet_failures() {