Added Warnings in case DO records to not exist
This commit is contained in:
parent
8fb399ad68
commit
f92b4be6d8
1 changed files with 4 additions and 0 deletions
|
@ -106,6 +106,8 @@ if agent_update_dns_do_domain=$(_update_dns_do_get_domain); then
|
||||||
-H "Authorization: Bearer $agent_update_dns_do_token" \
|
-H "Authorization: Bearer $agent_update_dns_do_token" \
|
||||||
-d '{"data":"'$DIP_CUR_IP'"}' \
|
-d '{"data":"'$DIP_CUR_IP'"}' \
|
||||||
"https://api.digitalocean.com/v2/domains/$agent_update_dns_do_domain/records/$record_id4" > /dev/null;
|
"https://api.digitalocean.com/v2/domains/$agent_update_dns_do_domain/records/$record_id4" > /dev/null;
|
||||||
|
else
|
||||||
|
logerr "WARN: No A record exists for $agent_update_dns_do_domain"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -121,6 +123,8 @@ if agent_update_dns_do_domain=$(_update_dns_do_get_domain); then
|
||||||
-H "Authorization: Bearer $agent_update_dns_do_token" \
|
-H "Authorization: Bearer $agent_update_dns_do_token" \
|
||||||
-d '{"data":"'$DIP_CUR_IP'"}' \
|
-d '{"data":"'$DIP_CUR_IP'"}' \
|
||||||
"https://api.digitalocean.com/v2/domains/$agent_update_dns_do_domain/records/$record_id6" > /dev/null;
|
"https://api.digitalocean.com/v2/domains/$agent_update_dns_do_domain/records/$record_id6" > /dev/null;
|
||||||
|
else
|
||||||
|
logerr "WARN: No AAAA record exists for $agent_update_dns_do_domain"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue