Add post-create hook
Note that this is invoked *before* the application is deployed, so it's usage is quite different than a potential post-successful-create hook.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
|
||||
source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
||||
source "$PLUGIN_AVAILABLE_PATH/apps/functions"
|
||||
|
||||
git_build_app_repo() {
|
||||
verify_app_name "$1"
|
||||
@@ -14,6 +15,7 @@ git_build_app_repo() {
|
||||
chmod 755 $TMP_WORK_DIR
|
||||
unset GIT_DIR GIT_WORK_TREE
|
||||
pushd $TMP_WORK_DIR > /dev/null
|
||||
[[ ! -d "$DOKKU_ROOT/$APP" ]] && apps_create $APP
|
||||
git clone -q "$DOKKU_ROOT/$APP" "$TMP_WORK_DIR" &> /dev/null
|
||||
git config advice.detachedHead false
|
||||
git checkout "$REV" &> /dev/null
|
||||
|
||||
Reference in New Issue
Block a user