[Lsb-messages] /var/www/bzr/lsb/devel/puppet-lsb r724: Fix puppet health report script's tempfile handling.

Jeff Licquia licquia at linuxfoundation.org
Thu Feb 22 14:02:44 UTC 2018


------------------------------------------------------------
revno: 724
committer: Jeff Licquia <licquia at linuxfoundation.org
branch nick: puppet-lsb
timestamp: Thu 2018-02-22 09:02:44 -0500
message:
  Fix puppet health report script's tempfile handling.
  
  Under certain circumstances, the old script would try to use the path
  it found/created in /tmp without the "/tmp/" part.
modified:
  modules/puppet/files/puppet-agent-health-report
-------------- next part --------------
=== modified file 'modules/puppet/files/puppet-agent-health-report'
--- a/modules/puppet/files/puppet-agent-health-report	2017-09-09 19:39:57 +0000
+++ b/modules/puppet/files/puppet-agent-health-report	2018-02-22 14:02:44 +0000
@@ -26,7 +26,7 @@
 [ 0${HASTEMP} -lt 01 ] && {
 	TEMP_PATH=$(mktemp -d --tmpdir ${BAS}.XXXXXXXXXX)
 	}
-TEMP_PATH=`ls /tmp | grep "${BAS}" | sort | tail -1 `
+TEMP_PATH=`ls /tmp/* | grep "${BAS}" | sort | tail -1 `
 [ "x${TEMP_PATH}" = "x" ] && {
 	echo "error: cannot see a working TEMP_PATH for ${BAS} " 1>&2
 	echo " ... bailing" 1>&2



More information about the lsb-messages mailing list