diff --git a/scripts/ZoneMinder/lib/ZoneMinder/ConfigData.pm.in b/scripts/ZoneMinder/lib/ZoneMinder/ConfigData.pm.in index 00015ae24..acd2464bf 100644 --- a/scripts/ZoneMinder/lib/ZoneMinder/ConfigData.pm.in +++ b/scripts/ZoneMinder/lib/ZoneMinder/ConfigData.pm.in @@ -400,7 +400,22 @@ our @options = ( type => $types{boolean}, 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', default => 'no', @@ -424,7 +439,6 @@ our @options = ( }, { name => 'ZM_OPT_GOOG_RECAPTCHA_SITEKEY', - default => '...Insert your recaptcha site-key here...', description => 'Your recaptcha site-key', help => q`You need to generate your keys from the Google reCaptcha website. diff --git a/scripts/zmdc.pl.in b/scripts/zmdc.pl.in index 7813e7176..18ae27844 100644 --- a/scripts/zmdc.pl.in +++ b/scripts/zmdc.pl.in @@ -104,6 +104,10 @@ my @daemons = ( 'zmtelemetry.pl' ); +if ($Config{ZM_OPT_USE_EVENTNOTIFICATION}) { + push @daemons,'zmeventnotification.pl'; +} + my $command = shift @ARGV; if( ! $command ) { print( STDERR "No command given\n" ); diff --git a/scripts/zmpkg.pl.in b/scripts/zmpkg.pl.in index d34b93e71..d772c9944 100644 --- a/scripts/zmpkg.pl.in +++ b/scripts/zmpkg.pl.in @@ -232,6 +232,7 @@ if ( $command =~ /^(?:start|restart)$/ ) { # This is now started unconditionally runCommand('zmdc.pl start zmfilter.pl'); + if ( $Config{ZM_RUN_AUDIT} ) { if ( $Server and exists $$Server{'zmaudit'} and ! $$Server{'zmaudit'} ) { Debug("Not running zmaudit.pl because it is turned off for this server."); @@ -256,6 +257,9 @@ if ( $command =~ /^(?:start|restart)$/ ) { if ( $Config{ZM_TELEMETRY_DATA} ) { runCommand('zmdc.pl start zmtelemetry.pl'); } + if ($Config{ZM_OPT_USE_EVENTNOTIFICATION} ) { + runCommand('zmdc.pl start zmeventnotification.pl'); + } if ( $Server and exists $$Server{'zmstats'} and ! $$Server{'zmstats'} ) { Debug("Not running zmstats.pl because it is turned off for this server."); } else {