fixed echo

This commit is contained in:
Shihaam Abdul Rahman 2021-04-23 11:48:53 +05:00
parent 108b4ee1e8
commit 0c9d3ec03c
2 changed files with 3 additions and 3 deletions

View File

@ -28,7 +28,7 @@ else
fi
DIP=$(curl -s -b /tmp/dcookies \
DHIRAAGU_IP=$(curl -s -b /tmp/dcookies \
$DHIRAAGU_HOME_URL \
| grep 'IP Address' -A1 \
| tail -n1 \
@ -36,6 +36,6 @@ DIP=$(curl -s -b /tmp/dcookies \
| cut -f1 -d '<' \
| cut --complement -d '>' -f 1)
echo IP Address = $DIP
echo IP Address = $DHIRAAGU_IP
rm /tmp/dcookies

View File

@ -47,7 +47,7 @@ curl -s -X PUT $CF_API_URL/zones/$CF_ZONE_ID/dns_records/$CF_DNS_RECORDS \
--data '{"type":"A","name":"'${CF_DOMAIN}'","content":"'${DHIRAAGU_IP}'","ttl":120,"proxied":false}' > /dev/null
#Print IP address to console
echo IP Address = $DIP
echo IP Address = $DHIRAAGU_IP
#delete the cookie from /tmp directory
rm /tmp/dcookies