ddclient / ddclient

Ddclient updates dynamic DNS entries for accounts on a wide range of dynamic DNS services.

Home Page:https://ddclient.net

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

-debug -verbose not helping in problem resolution (GoDaddy) (raspberrypi4)

MarkGotLasagna opened this issue · comments

The command sudo ddclient -daemon=0 -debug -verbose -noquiet -file /etc/ddclient/ddclient.conf does not help in problem resolution as it does not print relevant information. When using the following configuration

daemon=300
syslog=yes
mail=root
mail-failure=root
pid=/var/run/ddclient.pid
ssl=yes

protocol=godaddy
login=███
password=███
zone=maruko.it
ttl=600

ddclient yields the following output. What I expect is GET/POST requests information which I'm used to see when running previous stable versions (like v3.10.0). I'm currently using v3.11.2 latest from GitHub, as it should support GoDaddy.

The procedures I followed when manually installing are the ones listed in the README.md.

Your config is missing the last line (see here)
Without it ddclient does not recognize the provider configuration.

If you only changed the ddclient version without changing the config, logs from that v3.10.0 version to compare against would be great

Can you explain to me what purpose that line serves? I've been querying the API and I did not find the need to specify such an option as "hostname.domain.tld" to update the IP. The following code snippet works just fine.

curl -s -X PUT "https://api.godaddy.com/v1/domains/maruko.it/records/A/@" \
        -H "accept: application/json" \
        -H "Content-Type: application/json" \
        -H "Authorization: sso-key ${gdapikey}" \     # login:secret
        -d "[{\"data\": \"${myip}\"}]"                # curl -s "https://api.ipify.org"

Here ddclient's help prompt for godaddy. I'm probably missing out on some basic knowledge.

When you use curl your setup needs to be in the format your provider (godaddy) understands - like your example line. When you use ddclient, your config must be in the format ddclient understands.

Note that if you are comfortable with just throwing such a curl line into cron or similar for your dynamic DNS, you don't need ddclient. ddclient is useful if you're not comfortable curl-ing around in provider APIs, if you want stuff like rate limiting, caching to prevent redundant API accesses, need to update multiple domains at once, want to retrieve IPs from interfaces or external devices etc.

As for why that line is needed - that's for the admittedly quirky config format of ddclient. At the core of that format is one or more entries of (sub)domains. Each of those has a set of attributes (provider, login, password) - most of which vary depending on the provider. In the example of godaddy, each subdomain requires a login, a password, the DNS zone and the ttl of the record.
From your curl line it seems you just want to update a single record, in which case you just need to add the "@" to indicate the domain you want to update is equal to the zone:

protocol=godaddy
login=███
password=███
zone=maruko.it
ttl=600
@

For example, if instead you were to want to update a.example.com and b.example.com in the example.com zone, you'd have this:

protocol=godaddy
login=███
password=███
zone=example.com
ttl=600
a.example.com,b.example.com

This sums it up clearly. I'm closing.