EvertJob

Untitled

Jan 29th, 2019
152
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.38 KB | None | 0 0
  1. #!/bin/sh
  2. TelegramBotToken=
  3. Chatid=-
  4. SnapFile="/var/tmp/snapshot.jpg"
  5. URL="http://192.168.2.220/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=wuuPhkmUCeI9WG7C&user=admin&password="
  6.  
  7. wget -d -O $SnapFile $URL >> wget_start.log 2>&1
  8. curl -s -v -X POST "https://api.telegram.org/bot"$TelegramBotToken"/sendPhoto" -F chat_id=$Chatid -F photo="@$SnapFile"  >> curl.log 2>&1
  9. /bin/rm $SnapFile
Advertisement
Add Comment
Please, Sign In to add comment