feat: allow users to specify wildcard domains

Closes #3075
This commit is contained in:
Jose Diaz-Gonzalez committed 2019-05-20 21:03:55 -07:00
1 parent 0087296bd3
commit b921aed073
2 files changed
+6 -1

No files matched your search

+1 -1
View File
@@ -312,7 +312,7 @@ is_global_vhost_enabled() {
is_valid_hostname() { is_valid_hostname() {
declare desc="return 0 if argument is a valid hostname; else return 1" declare desc="return 0 if argument is a valid hostname; else return 1"
local hostname_string="${1,,}" local hostname_string="${1,,}"
local hostname_regex='^([a-z0-9\*-]+\.)*[a-z0-9\*-]+$' local hostname_regex='^([a-z0-9\.\*-]+\.)*[a-z0-9\*-]+$'
if [[ $hostname_string =~ $hostname_regex ]]; then if [[ $hostname_string =~ $hostname_regex ]]; then
return 0 return 0
else else
+5
View File
@@ -45,6 +45,11 @@ teardown() {
echo "status: $status" echo "status: $status"
assert_success assert_success
run /bin/bash -c "dokku domains:add $TEST_APP .dokku.me"
echo "output: $output"
echo "status: $status"
assert_success
run /bin/bash -c "dokku domains $TEST_APP 2>/dev/null" run /bin/bash -c "dokku domains $TEST_APP 2>/dev/null"
echo "output: $output" echo "output: $output"
echo "status: $status" echo "status: $status"