Don't check local domain

This commit is contained in:
Bob Mottram 2016-10-19 20:17:17 +01:00
parent 5cbfad1a5a
commit 84d6247463
1 changed files with 13 additions and 11 deletions

View File

@ -323,18 +323,20 @@ function check_domains {
for d in "${domains_array[@]}"
do
domain_param=$(echo "$d" | awk -F '=' '{print $1}')
if [[ "$domain_param" != "DEFAULT_DOMAIN_NAME" && "$domain_param" != "${PROJECT_NAME}.local" ]]; then
if [[ "$domain_param" != "DEFAULT_DOMAIN_NAME" ]]; then
domain_value=$(echo "$d" | awk -F '=' '{print $2}')
item_in_array "${domain_value}" "${checked_domains[@]}"
if [[ $? != 0 ]]; then
# test that this is a valid domain name
function_check test_domain_name
test_domain_name "$domain_value"
# add it to the list of domains
checked_domains+=("$domain_value")
else
echo $"Domain ${domain_value} collides with another app. The domain for each app should be unique."
exit 673925
if [[ "$domain_value" != "${PROJECT_NAME}.local" ]]; then
item_in_array "${domain_value}" "${checked_domains[@]}"
if [[ $? != 0 ]]; then
# test that this is a valid domain name
function_check test_domain_name
test_domain_name "$domain_value"
# add it to the list of domains
checked_domains+=("$domain_value")
else
echo $"Domain ${domain_value} collides with another app. The domain for each app should be unique."
exit 673925
fi
fi
fi
done