Skip to content

Instantly share code, notes, and snippets.

@alpsayin
Created November 28, 2016 16:03
Show Gist options
  • Save alpsayin/0db7202fe70bf22b5220331270fd558b to your computer and use it in GitHub Desktop.
Save alpsayin/0db7202fe70bf22b5220331270fd558b to your computer and use it in GitHub Desktop.
#!/bin/bash
logfile="/dev/null"
username="username"
password="password"
hostname=hostname.no-ip.org
response=`/usr/bin/curl --silent --user-agent 'CustomCurlUpdaterFromMyRasPi/1.0 username@email.com' 'https://'$username':'$password'@dynupdate.no-ip.com/nic/update?hostname='$hostname`
result=`echo $response | awk '{ print $1 }'`
myip=`echo $response | awk '{ print $2 }'`
echo $response
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment