- Create Account

Send IP Script

Forums > Tech Tips > Send IP Script
Author
Message

1) admin Group: Moderators
Posts: 61 Joined: 10 Feb 2021 Location: Southport IP: 212.159.---
#!/bin/sh
recipients="you@yourdomain.com"
ip="`wget -O  - http://dynupdate.no-ip.com/ip.php 2>/dev/null`"
mail -s "`hostname  -f` now at $ip" $recipients <<EOF
As of `date` the external IP of `hostname -f` is $ip
EOF
Look afar and see the end from the beginning

Sorry, this topic is not accepting new posts.