GiveMeAName
New Around Here
Hi,
I appear to be having issues with getting the ddns-start to work,
I am using the below script named ddns-start in the location
/jffs/scripts/, which when ran does not seem to throw any errors, however my cloudflare dns does not appear to update. In addition I have set the DDNS in the routers GUI to enabled, custom and have the hostname set to to the domain i wish to use but it is currently saying "Request Error! Please try again" every time i go back onto the DDNS page.
I have tried factory restoring the router but to no avail. any help on where I am going wrong would be greatly appreciated
EMAIL="REDACTED"
ZONEID="REDACTED"
API="REDACTED"
RECORDID="REDACTED"
RECORDNAME="REDACTED"
IP=${1}
curl -fs -o /dev/null -X PUT "https://api.cloudflare.com/client/v4/zones/$ZONEID/dns_records/$RECORDID" \
-H "X-Auth-Email: $EMAIL" \
-H "X-Auth-Key: $API" \
-H "Content-Type: application/json" \
--data "{\"type\":\"A\",\"name\":\"$RECORDNAME\",\"content\":\"$IP\",\"ttl\":120,\"proxied\":false}"
if [ $? -eq 0 ]; then
/sbin/ddns_custom_updated 1
else
/sbin/ddns_custom_updated 0
fi
I appear to be having issues with getting the ddns-start to work,
I am using the below script named ddns-start in the location
/jffs/scripts/, which when ran does not seem to throw any errors, however my cloudflare dns does not appear to update. In addition I have set the DDNS in the routers GUI to enabled, custom and have the hostname set to to the domain i wish to use but it is currently saying "Request Error! Please try again" every time i go back onto the DDNS page.
I have tried factory restoring the router but to no avail. any help on where I am going wrong would be greatly appreciated
EMAIL="REDACTED"
ZONEID="REDACTED"
API="REDACTED"
RECORDID="REDACTED"
RECORDNAME="REDACTED"
IP=${1}
curl -fs -o /dev/null -X PUT "https://api.cloudflare.com/client/v4/zones/$ZONEID/dns_records/$RECORDID" \
-H "X-Auth-Email: $EMAIL" \
-H "X-Auth-Key: $API" \
-H "Content-Type: application/json" \
--data "{\"type\":\"A\",\"name\":\"$RECORDNAME\",\"content\":\"$IP\",\"ttl\":120,\"proxied\":false}"
if [ $? -eq 0 ]; then
/sbin/ddns_custom_updated 1
else
/sbin/ddns_custom_updated 0
fi