Commit a114476e authored by Lukas Fleischer's avatar Lukas Fleischer
Browse files

Make the notification script configurable



Add a configuration option to set the path of the notification script.

Signed-off-by: Lukas Fleischer's avatarLukas Fleischer <lfleischer@archlinux.org>
parent 0c599b39
......@@ -32,6 +32,7 @@ enable-maintenance = 1
maintenance-exceptions = 127.0.0.1
[notifications]
notify-cmd = /srv/http/aurweb/scripts/notify.py
sendmail = /usr/bin/sendmail
sender = notify@aur.archlinux.org
reply-to = noreply@aur.archlinux.org
......
......@@ -1282,7 +1282,7 @@ function account_set_ssh_keys($uid, $ssh_keys, $ssh_fingerprints) {
* @return void
*/
function notify($params, $text='') {
$cmd = realpath('../../scripts/notify.py');
$cmd = config_get('notifications', 'notify-cmd');
foreach ($params as $param) {
$cmd .= ' ' . escapeshellarg($param);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment