This commit is contained in:
Pliable Pixels 2018-03-29 08:47:55 -04:00
parent 06f10e0ed3
commit 990d60926e
3 changed files with 26 additions and 1 deletions

View File

@ -375,7 +375,22 @@ our @options = (
type => $types{boolean}, type => $types{boolean},
category => 'system', category => 'system',
}, },
# PP - Google reCaptcha settings {
name => 'ZM_OPT_USE_EVENTNOTIFICATION',
default => 'no',
description => 'Enable 3rd party Event Notification Server',
help => q`
zmeventnotification is a 3rd party event notification server
that is used to get notifications for alarms detected by ZoneMinder
in real time. zmNinja requires this server for push notifications to
mobile phones. This option only enables the server if its already installed.
Please visit https://github.com/pliablepixels/zmeventserver for installation
instructions.
`,
type => $types{boolean},
category => 'system',
},
# Google reCaptcha settings
{ {
name => 'ZM_OPT_USE_GOOG_RECAPTCHA', name => 'ZM_OPT_USE_GOOG_RECAPTCHA',
default => 'no', default => 'no',

View File

@ -99,6 +99,11 @@ my @daemons = (
'zmtelemetry.pl' 'zmtelemetry.pl'
); );
if ($Config{ZM_OPT_USE_ZMEVENTNOTIFICATION})
{
push @daemons,'zmeventnotification.pl';
}
my $command = shift @ARGV; my $command = shift @ARGV;
if( !$command ) if( !$command )
{ {

View File

@ -225,6 +225,7 @@ if ( $command =~ /^(?:start|restart)$/ ) {
# This is now started unconditionally # This is now started unconditionally
runCommand('zmdc.pl start zmfilter.pl'); runCommand('zmdc.pl start zmfilter.pl');
if ( $Config{ZM_RUN_AUDIT} ) { if ( $Config{ZM_RUN_AUDIT} ) {
runCommand('zmdc.pl start zmaudit.pl -c'); runCommand('zmdc.pl start zmaudit.pl -c');
} }
@ -241,6 +242,10 @@ if ( $command =~ /^(?:start|restart)$/ ) {
if ( $Config{ZM_TELEMETRY_DATA} ) { if ( $Config{ZM_TELEMETRY_DATA} ) {
runCommand('zmdc.pl start zmtelemetry.pl'); runCommand('zmdc.pl start zmtelemetry.pl');
} }
if ($Config{ZM_OPT_USE_ZMEVENTNOTIFICATION} )
{
runCommand('zmdc.pl start zmeventnotification.pl');
}
} else { } else {
$retval = 1; $retval = 1;
} }