Skip to content

Commit

Permalink
dns_rackspace: search for domain
Browse files Browse the repository at this point in the history
The current call uses the /domains end-point which lists all domains.
This only returns 100 domains at a time, so for long domain lists you
may not match and find the required ID.

Switch to using the search interface that only returns values matching
the requested domain.  This will avoid missing results.

Closes: #2944
  • Loading branch information
ianw committed May 18, 2020
1 parent 9190fdd commit 6ec3c92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dnsapi/dns_rackspace.sh
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ _get_root_zone() {
#not valid
return 1
fi
if ! _rackspace_rest GET "$RACKSPACE_Tenant/domains"; then
if ! _rackspace_rest GET "$RACKSPACE_Tenant/domains/search?name=$h"; then
return 1
fi
_debug2 response "$response"
Expand Down

0 comments on commit 6ec3c92

Please sign in to comment.