diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2019-09-03 10:23:38 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2019-09-03 10:23:38 +0000 |
commit | 574098461cd45be12a497afbdac6f93c58978387 (patch) | |
tree | 9eb60a5930b7c20d42f7fde1e234cae3968ed3d9 /packaging/installer/kickstart.sh | |
parent | Adding upstream version 1.16.1. (diff) | |
download | netdata-574098461cd45be12a497afbdac6f93c58978387.tar.xz netdata-574098461cd45be12a497afbdac6f93c58978387.zip |
Adding upstream version 1.17.0.upstream/1.17.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'packaging/installer/kickstart.sh')
-rwxr-xr-x | packaging/installer/kickstart.sh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/packaging/installer/kickstart.sh b/packaging/installer/kickstart.sh index d396f139e..bab95fda2 100755 --- a/packaging/installer/kickstart.sh +++ b/packaging/installer/kickstart.sh @@ -304,7 +304,7 @@ if [ "${INTERACTIVE}" = "0" ]; then fi TMPDIR=$(create_tmp_directory) -cd ${TMPDIR} || : +cd "${TMPDIR}" dependencies @@ -328,7 +328,9 @@ cd netdata-* || fatal "Cannot cd to netdata source tree" if [ -x netdata-installer.sh ]; then progress "Installing netdata..." run ${sudo} ./netdata-installer.sh ${NETDATA_UPDATES} ${NETDATA_INSTALLER_OPTIONS} "${@}" || fatal "netdata-installer.sh exited with error" - rm -rf "${TMPDIR}" >/dev/null 2>&1 + if [ -d "${TMPDIR}" ] && [ ! "${TMPDIR}" = "/" ]; then + run ${sudo} rm -rf "${TMPDIR}" >/dev/null 2>&1 + fi else fatal "Cannot install netdata from source (the source directory does not include netdata-installer.sh). Leaving all files in ${TMPDIR}" fi |