mirror of
https://github.com/hoellen/dockerfiles.git
synced 2025-04-20 04:19:18 +00:00
ngxproxy: verify domain validity
This commit is contained in:
parent
a803fc3ee8
commit
eb5e709797
@ -11,13 +11,18 @@ done
|
|||||||
|
|
||||||
while [ "$DOMAIN" == "" ]; do
|
while [ "$DOMAIN" == "" ]; do
|
||||||
read -p "Domain: " DOMAIN
|
read -p "Domain: " DOMAIN
|
||||||
|
if [ "$(dig +short ${DOMAIN})" == "" ]; then
|
||||||
|
echo "WARNING: ${DOMAIN} couldn't be resolved. It may not work!"
|
||||||
|
echo "HINT: Is this domain correct? Did you update your DNS zone?"
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
while [ "$CONTAINER" == "" ]; do
|
while [ "$CONTAINER" == "" ]; do
|
||||||
read -p "Container: " CONTAINER
|
read -p "Container: " CONTAINER
|
||||||
ping -c 1 ${CONTAINER} >/dev/null 2>&1
|
ping -c 1 ${CONTAINER} >/dev/null 2>&1
|
||||||
if [ "$?" != "0" ]; then
|
if [ "$?" != "0" ]; then
|
||||||
echo "WARNING: ${CONTAINER} seems to be unavailable."
|
echo "WARNING: ${CONTAINER} seems to be unavailable. It may not work!"
|
||||||
|
echo "HINT: Did you correctly link the container?"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user