Skip to content

Instantly share code, notes, and snippets.

@nckltcha
Created March 22, 2012 14:32
Show Gist options
  • Select an option

  • Save nckltcha/2158663 to your computer and use it in GitHub Desktop.

Select an option

Save nckltcha/2158663 to your computer and use it in GitHub Desktop.
Check Service is Running and Post to Prowl
#!/bin/sh
# Name of Service
SERVICE=sick
if ps | grep -v grep | grep $SERVICE > 0
then
wget --post-data 'apikey=XXXX&application=DiskStation&event=SickBeard&description=SickBeard is Running' -O - http://api.prowlapp.com/publicapi/add
else
wget --post-data 'apikey=XXXX&application=DiskStation&event=SickBeard&description=SickBeard is not Running' -O - http://api.prowlapp.com/publicapi/add
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment