unused code removed

This commit is contained in:
peterkelm 2019-10-27 16:58:36 +01:00 committed by GitHub
parent 1271f97b66
commit c1b089d1c3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 18 deletions

View File

@ -30,14 +30,6 @@ dns_variomedia_add() {
_debug _sub_domain "$_sub_domain"
_debug _domain "$_domain"
# _debug 'Getting txt records'
# _variomedia_rest GET "/dns-records?filter[domain]=$_domain"
# if printf "%s\n" "$response" | grep "\"record_type\": \"A\", \"fqdn\": \"$fulldomain\"" >/dev/null; then
# _err 'Error'
# return 1
# fi
if ! _variomedia_rest POST "dns-records" "{\"data\": {\"type\": \"dns-record\", \"attributes\": {\"record_type\": \"TXT\", \"name\": \"$_sub_domain\", \"domain\": \"$_domain\", \"data\": \"$txtvalue\", \"ttl\":300}}}"; then
_err "$response"
return 1
@ -119,13 +111,7 @@ _get_root() {
_sub_domain="$(echo "$fulldomain" | sed "s/\\.$h\$//")"
_domain=$h
return 0
# else
# _err 'Invalid domain'
# return 1
fi
# else
# _err "$response"
# return 1
fi
i=$(_math "$i" + 1)
done
@ -141,10 +127,6 @@ _variomedia_rest() {
data="$3"
_debug "$ep"
# api_key_trimmed=$(echo $VARIOMEDIA_API_TOKEN | tr -d '"')
# export _H1="Api-Key: $api_key_trimmed"
export _H1="Authorization: token $VARIOMEDIA_API_TOKEN"
export _H2="Content-Type: application/vnd.api+json"
export _H3="Accept: application/vnd.variomedia.v1+json"