Edugate/ResourceRegistry — pull request #32 by janul (2014-01-28 10:38:28+00:00)
Title: closes #17

There is new notification system.
Since now Jagger does't send mails to Administrator group members.
User needs to subscribe notification on his profile page.
There are number of types of subscription like system notifications, registratrion requests and so on.
Notifications are create in mailqueue table so you need to have scirpt running in background to monitor it and send unsent mail.
Here below is init script for sending mails from the mailqueue (you may need to modify it to match you server env)
---------------------------------
#!/bin/bash

### BEGIN INIT INFO
# Required-Start: $syslog $network $local_fs $remote_fs
# Required-Stop: $syslog $network $local_fs $remote_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Gearman distributed work system
### END INIT INFO
ARGS="PATH_TO_JAGGER_INSTANCE/index.php gworkers mailqueuesender"
DAEMON="/usr/bin/php"
PIDFILE="/var/run/jagger/mailqueuesender.pid"
USER="www-data"

if [ ! -d /var/run/jagger ] ; then
mkdir /var/run/jagger
fi

case "$1" in
start)
echo "Starting g-worker: ${ARGS}"
/sbin/start-stop-daemon --start --pidfile $PIDFILE \
--user $USER --group $USER \
-b --make-pidfile \
--chuid $USER \
--exec $DAEMON $ARGS
;;
stop)
echo "Stopping server"
/sbin/start-stop-daemon --stop --pidfile $PIDFILE --verbose
;;
*)
echo "Usage: /etc/init.d/jaggermailer {start|stop}"
exit 1
;;
esac

exit 0