support dockerfiles without expose command. closes #1083

This commit is contained in:
Michael Hobbs
2015-04-03 12:13:39 -07:00
parent 5c938fee8a
commit c2053d5322
7 changed files with 64 additions and 1 deletions

View File

@@ -35,7 +35,7 @@ case "$1" in
dockerfile)
# extract first port from Dockerfile
DOCKERFILE_PORT=$(grep EXPOSE Dockerfile | head -1 | awk '{ print $2 }')
DOCKERFILE_PORT=$(grep EXPOSE Dockerfile | head -1 | awk '{ print $2 }' || true)
[[ -n "$DOCKERFILE_PORT" ]] && dokku config:set-norestart $APP DOKKU_DOCKERFILE_PORT=$DOCKERFILE_PORT
# sticking with same pattern of building app image before pre-build for now.