diff -urN smeserver-zoneminder-1.0.old/createlinks smeserver-zoneminder-1.0/createlinks --- smeserver-zoneminder-1.0.old/createlinks 2021-02-16 10:40:17.775163164 +0000 +++ smeserver-zoneminder-1.0/createlinks 2021-02-16 11:43:05.851230706 +0000 @@ -4,7 +4,7 @@ my $event; # Runlevel init links. -service_link_enhanced("zoneminder", "S99", "7"); +#service_link_enhanced("zoneminder", "S99", "7"); @@ -14,7 +14,7 @@ templates2events("/etc/httpd/conf/httpd.conf", $event); templates2events("/etc/zm/zm.conf", $event); event_link("zoneminder", $event, "10"); -safe_symlink("sigusr1", "root/etc/e-smith/events/$event/services2adjust/httpd-e-smith"); +safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/httpd-e-smith"); # add expand zm.conf foreach my $event (qw(post-upgrade bootstrap-console-save console-save remoteaccess-update php-update webapps-update)){ @@ -22,4 +22,28 @@ event_link("zoneminder", $event, "10"); } +# our event specific for updating with yum without reboot +$event = "smeserver-zoneminder-update"; +#add here the path to your templates needed to expand +#see the /etc/systemd/system-preset/49-koozali.preset should be present for systemd integration on all you yum update event + +foreach my $file (qw( + /etc/systemd/system-preset/49-koozali.preset + /etc/zm/zm.conf + /etc/httpd/conf/httpd.conf + /etc/e-smith/sql/init/30zoneminder +)) +{ + templates2events( $file, $event ); +} +#action needed in case we have a systemd unit +event_link("systemd-default", $event, "10"); +event_link("systemd-reload", $event, "50"); + +#action specific to this package +#event_link("conf-timezone", $event, "30"); +#services we need to restart +safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/httpd-e-smith"); +safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/mysql.init"); +safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/zoneminder") diff -urN smeserver-zoneminder-1.0.old/root/usr/lib/systemd/system/zoneminder.service.d/50koozali.conf smeserver-zoneminder-1.0/root/usr/lib/systemd/system/zoneminder.service.d/50koozali.conf --- smeserver-zoneminder-1.0.old/root/usr/lib/systemd/system/zoneminder.service.d/50koozali.conf 1970-01-01 01:00:00.000000000 +0100 +++ smeserver-zoneminder-1.0/root/usr/lib/systemd/system/zoneminder.service.d/50koozali.conf 2021-02-16 10:56:20.781430407 +0000 @@ -0,0 +1,6 @@ +[Unit] +After=wan.service +After=networking.service +[Install] +WantedBy=sme-server.target +