From 22beb6c00714cfa1055270acbffcbedc2549b425 Mon Sep 17 00:00:00 2001 From: Alex Ernst Date: Fri, 22 Aug 2014 12:36:20 +0200 Subject: [PATCH] move post-deploy hook Write $DOKKU_ROOT/$APP/URL before post-deploy hook. --- dokku | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/dokku b/dokku index dd445a9ba..d6d23a712 100755 --- a/dokku +++ b/dokku @@ -77,15 +77,16 @@ case "$1" in trap kill_new INT TERM EXIT echo "-----> Running pre-flight checks" pluginhook check-deploy $id $APP $port - echo "-----> Running post-deploy" - pluginhook post-deploy $APP $port - trap - INT TERM EXIT # now using the new container echo $id > "$DOKKU_ROOT/$APP/CONTAINER" echo $port > "$DOKKU_ROOT/$APP/PORT" echo "http://$(< "$DOKKU_ROOT/HOSTNAME"):$port" > "$DOKKU_ROOT/$APP/URL" + echo "-----> Running post-deploy" + pluginhook post-deploy $APP $port + trap - INT TERM EXIT + # kill the old container if [[ -n "$oldid" ]]; then docker inspect $oldid &> /dev/null && docker kill $oldid > /dev/null