Ad Widget

Collapse

Whatsapp alert

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • brekler
    Junior Member
    • Jul 2014
    • 26

    #1

    Whatsapp alert

    Hello guys, im using yowsup to alert by whatsapp.
    But im having a problem. My zabbix says its sending the alert by script, and my script is saving a log correctly,
    But im not receiving the msg. Does anyone use this alert ?
    Zabbix can do a log of the script part ?

    my script is this....

    #!/bin/bash
    #
    # Script para o YowSup para enviar mensagens via WhatsApp
    LOGFILE="/var/log/zabbix/whatsapp.log"
    DEST="$1"
    MSG="$3"
    YOWSUP="/etc/yowsup/yowsup-master/yowsup-cli"
    YCONF="/etc/zabbix/zap.conf"
    sudo $YOWSUP demos -c $YCONF -s ${DEST} "${MSG}"
    HORA=$(date +%d-%m-%Y-%H:%M:%S)
    echo "$HORA – To: '${DEST}' Text: '${MSG}'" >> ${LOGFILE}
  • brekler
    Junior Member
    • Jul 2014
    • 26

    #2
    guys! Just solved the problem.
    Changed this...

    sudo $YOWSUP demos -c $YCONF -s ${DEST} "${MSG}"
    to this
    $YOWSUP demos -c $YCONF -s ${DEST} "${MSG}"
    and it worked!= D

    Comment

    • Fabio Carretta
      Junior Member
      • Sep 2019
      • 1

      #3
      Hi brekler,
      can you help me? i'm new to zabbix.
      You can explain to me how to install yowsup on zabbix's appliance?
      Many thanks

      Comment

      Working...