Skip to content

Instantly share code, notes, and snippets.

@msurguy
Created November 30, 2017 05:16
Show Gist options
  • Select an option

  • Save msurguy/ac7304280c88d7409ffe78e63320cfd6 to your computer and use it in GitHub Desktop.

Select an option

Save msurguy/ac7304280c88d7409ffe78e63320cfd6 to your computer and use it in GitHub Desktop.
Raspberry Pi IP notification
#!/bin/bash
sleep 15
MYIP="$(/bin/hostname --all-ip-addresses)"
curl https://api.pushbullet.com/v2/pushes \
-u <your api token>: \
-d device_iden="<device ID from pushbullet>" \
-d type="note" \
-d title="Pi IP Address" \
-d body=$MYIP \
-X POST
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment