Fix issue when Dockerfile present but BUILDPACK_URL is set

This commit is contained in:
Domonkos Czinke
2016-02-10 13:11:56 +01:00
committed by Michael Hobbs
parent 2f0e52abe1
commit 1e3f29ad98

View File

@@ -32,7 +32,7 @@ git_build_app_repo() {
GIT_DIR="$DOKKU_ROOT/$APP" git tag -d "$TMP_TAG" &> /dev/null || true
find -name .git -prune -exec rm -rf {} \; > /dev/null
if [[ -f Dockerfile ]] && [[ "$([[ -f .env ]] && grep -q BUILDPACK_URL .env; echo $?)" != "0" ]] && [[ ! -f ".buildpacks" ]]; then
if [[ -f Dockerfile ]] && [[ "$([[ -f .env ]] && grep -q BUILDPACK_URL .env; echo $?)" != "0" ]] && [[ ! -f ".buildpacks" ]] && [[ "$(grep -q BUILDPACK_URL $DOKKU_ROOT/$APP/ENV)" ]]; then
plugn trigger pre-receive-app "$APP" "dockerfile" "$TMP_WORK_DIR" "$REV"
dokku receive "$APP" "dockerfile" "$TMP_WORK_DIR" | sed -u "s/^/"$'\e[1G'"/"
else