Skip to content

Instantly share code, notes, and snippets.

@srlemke
Last active September 21, 2017 14:44
Show Gist options
  • Select an option

  • Save srlemke/5906041cdee526b4312a4dc7bbb213d2 to your computer and use it in GitHub Desktop.

Select an option

Save srlemke/5906041cdee526b4312a4dc7bbb213d2 to your computer and use it in GitHub Desktop.
send external IP adress to telegram bot
#!/bin/bash
curl ifconfig.me > /tmp/Cur_IP > /dev/null
/usr/bin/curl -s -X POST https://api.telegram.org/bot319999999:AAFp3d8FM5h1RV8xxxxxxxxxxxxxxxxxxxx/sendMessage -d text=`cat /tmp/Cur_IP` -d chat_id=29999999 > /dev/null
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment