Skip to content

Commit 880ff55

Browse files
author
Seppo Enarvi
committed
Add a random delay before duckdns request
1 parent 6b7f143 commit 880ff55

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

duck/duck.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,8 @@
33
DOMAINS="YOUR_DOMAINS"
44
# Your DuckDNS Token
55
DUCKDNS_TOKEN="YOUR_DUCKDNS_TOKEN"
6-
curl -k -o /var/log/duck.log "https://www.duckdns.org/update?domains=${DOMAINS}&token=${DUCKDNS_TOKEN}&ip="
6+
7+
# A random delay to avoid every client contacting the duckdns server at the same moment
8+
sleep $((RANDOM % 30))
9+
# Request duckdns to update your domain name with your public IP address
10+
curl --silent --max-time 10 --output /dev/null "https://www.duckdns.org/update?domains=${DOMAINS}&token=${DUCKDNS_TOKEN}&ip="

0 commit comments

Comments
 (0)