Skip to content
Permalink
Browse files

Add nems-webhooktest

  • Loading branch information...
NEMS Linux
NEMS Linux committed Jul 29, 2019
1 parent b17229a commit c788f37d2803c33883ee82906bd0a235733acb78
Showing with 21 additions and 1 deletion.
  1. +5 −0 fixes.sh
  2. +0 −1 info2.sh
  3. +16 −0 webhooktest.sh
@@ -308,6 +308,11 @@ fi

if (( $(awk 'BEGIN {print ("'$ver'" >= "'1.5'")}') )); then

# Install nems-webhooktest command if not already
if [ ! -f /usr/local/bin/nems-webhooktest ]; then
ln -s /usr/local/share/nems/nems-scripts/webhooktest.sh /usr/local/bin/nems-webhooktest
fi

# Move NEMS TV Dashboard out of nems-www
if [[ ! -d /var/www/nems-tv ]]; then
cd /var/www
@@ -444,7 +444,6 @@ EOQ;
break;
}
@@ -0,0 +1,16 @@
#!/bin/env php
<?php
$user=trim(shell_exec('whoami'));
if ($user != 'root') die('You cannot run this program as ' . $user . '. Please use sudo.' . PHP_EOL);
echo 'Sending a webhook test... ';
$currentissueshead = 'NEMS Linux Test Notification';
$nemsstate = $state = $currentissues = 'Testing';
$fieldsarray[] = array(
'name' => 'Webhook Test',
'value' => 'Successful.',
'inline' => false
);
include('/root/nems/nems-tools/webhook');
echo 'Done.' . PHP_EOL;
?>

0 comments on commit c788f37

Please sign in to comment.
You can’t perform that action at this time.