From 3b64e84b8a2635fe24c181060c97f3429b07a94a Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Wed, 25 Nov 2015 20:15:51 -0700 Subject: [PATCH] Fixed installer bug: https://trello.com/c/5RcOfd3H Installer tried to always remove a file which was only created when doing a remote install. This was harmless, but caused a message, and since it did it with sudo, didn't work in the test environment. --- buildtools/installme | 4 +++- docfiles/Releases.c | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/buildtools/installme b/buildtools/installme index 0254775a..42ebc977 100755 --- a/buildtools/installme +++ b/buildtools/installme @@ -44,6 +44,7 @@ PRERELURL=$ROOTURL/Prereleases SRCROOT=https://github.com/assimilation/assimilation-official/raw NEOVERS=2.2.5 BUILDLOG=build.out +TARBALL='' DEBIAN_BASE_CMA_PKGS='python-pip python-flask lsof python-netaddr resource-agents @@ -1308,7 +1309,7 @@ fi TMPDIR=$(mktmpdir) cd $TMPDIR -trap 'cd /; rm -fr ${TMPDIR}; $LOCALSUDO rm -f ${TARBALL}' 0 +trap 'cd /; rm -fr ${TMPDIR}' 0 case $1 in cma|nanoprobe) echo "Installing release $REL of Assimilation $1 on $(uname -n)" @@ -1318,6 +1319,7 @@ case $1 in test $LOGME = false || loginstall $1 ;; remote) + trap 'cd /; rm -fr ${TMPDIR}; $LOCALSUDO rm -f ${TARBALL}' 0 shift printf 'Performing remote installation of %s on: [%s]\n' "$REL" "$*" remote_nano_install "$@" diff --git a/docfiles/Releases.c b/docfiles/Releases.c index 8cbb404a..c39cb4d9 100644 --- a/docfiles/Releases.c +++ b/docfiles/Releases.c @@ -7,6 +7,7 @@ @subsection BugFixes_1_1_1 Bug Fixes - Fixed notification API filter code - https://trello.com/c/RFpMIIhP - Fixed switch discovery - https://trello.com/c/ZJacf7EI +- Fixed installer to not remove file that doesn't exist - https://trello.com/c/5RcOfd3H @subsection Caveats_1_1_1 Caveats - Not compatible with database formats before 1.1.0 - Sudoers discovery is disabled for this release - will reappear later on