Skip to content

Commit

Permalink
Updated documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
senarvi committed Mar 29, 2021
1 parent 880ff55 commit b53f70c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/Accessing-your-Device-from-the-internet.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ first test the script to make sure it works `sudo ~/IOTstack/duck/duck.sh` then
Create a cron job by running the following command `crontab -e`

You will be asked to use an editor option 1 for nano should be fine
paste the following in the editor `*/5 * * * * sudo ~/IOTstack/duck/duck.sh >/dev/null 2>&1` then ctrl+s and ctrl+x to save
paste the following in the editor `*/5 * * * * ~/IOTstack/duck/duck.sh` then ctrl+s and ctrl+x to save

Your Public IP should be updated every five minutes

Expand Down
2 changes: 1 addition & 1 deletion duck/duck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ DOMAINS="YOUR_DOMAINS"
DUCKDNS_TOKEN="YOUR_DUCKDNS_TOKEN"

# A random delay to avoid every client contacting the duckdns server at the same moment
sleep $((RANDOM % 30))
sleep $((RANDOM % 60))
# Request duckdns to update your domain name with your public IP address
curl --silent --max-time 10 --output /dev/null "https://www.duckdns.org/update?domains=${DOMAINS}&token=${DUCKDNS_TOKEN}&ip="

0 comments on commit b53f70c

Please sign in to comment.