Skip to content

Commit 1302e50

Browse files
Subcursionfeckert
authored andcommitted
ddns-scripts: add type field for digitalocean API
DigitalOcean API requires a "type" JSON field to update a DNS record. This adds that while checking for IPv6 to change which record type to use. Without it, the API call fails, making the script unable to update the DNS records for DigitalOcean. Signed-off-by: Adam Beck <[email protected]>
1 parent 25b156a commit 1302e50

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

net/ddns-scripts/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk
88

99
PKG_NAME:=ddns-scripts
1010
PKG_VERSION:=2.8.2
11-
PKG_RELEASE:=59
11+
PKG_RELEASE:=60
1212

1313
PKG_LICENSE:=GPL-2.0
1414

net/ddns-scripts/files/usr/lib/ddns/update_digitalocean_com_v2.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
json_init
2525
json_add_string name "$username"
2626
json_add_string data "$__IP"
27+
[ $use_ipv6 -ne 0 ] && json_add_string type "AAAA" || json_add_string type "A"
2728

2829
__STATUS=$(curl -Ss -X PUT "https://api.digitalocean.com/v2/domains/${domain}/records/${param_opt}" \
2930
-H "Authorization: Bearer ${password}" \

0 commit comments

Comments
 (0)