/[smeserver]/rpms/e-smith-lib/sme10/e-smith-lib-2.6.0-bz11723.patch
ViewVC logotype

Contents of /rpms/e-smith-lib/sme10/e-smith-lib-2.6.0-bz11723.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Thu Oct 28 04:13:03 2021 UTC (3 years ago) by jpp
Branch: MAIN
CVS Tags: e-smith-lib-2_6_0-16_el7_sme, e-smith-lib-2_6_0-15_el7_sme, e-smith-lib-2_6_0-17_el7_sme, HEAD
* Thu Oct 28 2021 Jean-Philippe Pialasse <tests@pialasse.com> 2.6.0-15.sme
- add support for service with instances [SME: 11723]

1 diff -Nur --no-dereference e-smith-lib-2.6.0.old/root/usr/share/perl5/vendor_perl/esmith/util.pm e-smith-lib-2.6.0/root/usr/share/perl5/vendor_perl/esmith/util.pm
2 --- e-smith-lib-2.6.0.old/root/usr/share/perl5/vendor_perl/esmith/util.pm 2021-10-28 00:06:25.915000000 -0400
3 +++ e-smith-lib-2.6.0/root/usr/share/perl5/vendor_perl/esmith/util.pm 2021-10-28 00:09:41.931000000 -0400
4 @@ -1123,15 +1123,17 @@
5 {
6 my ($startScript) = glob("/etc/rc.d/rc7.d/S*$serviceName") ||'' ;
7 my ($systemdScript) = "/usr/lib/systemd/system/$serviceName.service" ||'';
8 + my $multiple = "$serviceName.service";
9 + ($multiple = $serviceName ) =~ s/([a-zA-Z0-9\-_.]+@)(.*)/$1.service/ if ( $serviceName =~ /@/ );
10
11 - unless ( -e $startScript or -e $systemdScript)
12 + unless ( -e $startScript or -e $systemdScript or -e "/usr/lib/systemd/system/$multiple")
13 {
14 warn "serviceControl: startScript not found "
15 . "for service $serviceName\n";
16 return 0;
17 }
18
19 - if (-e $systemdScript and ! -e $startScript){
20 + if ( (-e $systemdScript or -e "/usr/lib/systemd/system/$multiple") and ! -e $startScript){
21 # systemd is not aware of adjust, sigusr1, sigusr2, sigterm, sighup
22 $serviceAction = ( $serviceAction =~/^(adjust|graceful|sighup|sigusr1|sigusr2)$/ ) ? "reload-or-restart" : $serviceAction;
23 $serviceAction = ( $serviceAction eq "sigterm" ) ? "restart" : $serviceAction;

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed