From 83c13f1181c4062ca5296ea956e950064bde0ffe Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Thu, 18 Oct 2012 13:38:58 +0200 Subject: o Making all scripts be run from the root/ directory. Do not assume you're in current/. --- .app/lib/app-instance | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to '.app/lib/app-instance') diff --git a/.app/lib/app-instance b/.app/lib/app-instance index 89102b5..5b34bf1 100644 --- a/.app/lib/app-instance +++ b/.app/lib/app-instance @@ -191,7 +191,7 @@ method_install() { echo "Unpacking..." unzip -q -d $name/$instance/versions/$resolved_version $zip_file - if [ ! -d $apps/$name/$instance/versions/$resolved_version/root ] + if [ ! -d $name/$instance/versions/$resolved_version/root ] then echo "Invalid zip file, did not contain a ./root directory." >&2 exit 1 @@ -207,6 +207,7 @@ method_install() { if [ -x scripts/postinstall ] then echo "Running postinstall..." + cd root set +e env -i \ PATH=/bin:/usr/bin \ @@ -215,7 +216,7 @@ method_install() { APPSH_NAME=$name \ APPSH_INSTANCE=$instance \ APPSH_VERSION=$resolved_version \ - scripts/postinstall + ../scripts/postinstall set -e ret=`echo $?` if [ "$ret" != 0 ] -- cgit v1.2.3