Fix NO_VHOST check
It used to check if NO_VHOST is unset or set to the empty string It now checks if NO_VHOST is set to a non-empty string
This commit is contained in:
@@ -9,11 +9,11 @@ set +e
|
|||||||
NO_VHOST=$(dokku config:get $APP NO_VHOST)
|
NO_VHOST=$(dokku config:get $APP NO_VHOST)
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
if [[ -z "$NO_VHOST" ]]; then
|
if [[ -n "$NO_VHOST" ]]; then
|
||||||
echo "-----> NO_VHOST config detected"
|
echo "-----> NO_VHOST config detected"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -f "$DOKKU_ROOT/VHOST" && ! -z "$NO_VHOST" ]]; then
|
if [[ -f "$DOKKU_ROOT/VHOST" && ! -n "$NO_VHOST" ]]; then
|
||||||
VHOST=$(< "$DOKKU_ROOT/VHOST")
|
VHOST=$(< "$DOKKU_ROOT/VHOST")
|
||||||
SUBDOMAIN=${APP/%\.${VHOST}/}
|
SUBDOMAIN=${APP/%\.${VHOST}/}
|
||||||
hostname=$(: | pluginhook nginx-hostname $APP $SUBDOMAIN $VHOST)
|
hostname=$(: | pluginhook nginx-hostname $APP $SUBDOMAIN $VHOST)
|
||||||
|
|||||||
Reference in New Issue
Block a user