just wanted to share my reduced and adapted script to update a subdomain registered on namecheap.
It's the bare minimum required, plus the logging instruction.
Code: Select all
:global ddnshostname "SUBDOMAIN"
:global ddnsdomain "YOUR_DOMAIN.COM"
:global ddnspass "5f66f2af8491226967965b1eaea50265_<-YOUR_NAMECHEAP_DYNDNS_KEY"
:log info ("DDNS: Updating")
:local str "https://dynamicdns.park-your-domain.com/update\3Fhost=$ddnshostname&domain=$ddnsdomain&password=$ddnspass"
/tool fetch url=($str) mode=https keep-result=no
- You need read and test permission only
- It's tested and working with ROS 6.37.3 (stable)
- keep-result=no prevent the fetch command to save the result file on disk, which is out of the scope of the script
- You don't need to get your public IP from your WAN interface or wherever and send it, since namecheap use the source IP of the fetch command by default (ref: here)