From becaca29fe4c52becf4697fc27c9cbd6c27139da Mon Sep 17 00:00:00 2001 From: wangxiaopeng Date: Tue, 8 Sep 2015 04:51:51 -0400 Subject: [PATCH] Issue 157 add XCATSSLVER environment variable when it's set on sles11.x mn in conserver.cf for calling cons script to communicate with xcatd through tls --- xCAT-server/lib/xcat/plugins/conserver.pm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/xCAT-server/lib/xcat/plugins/conserver.pm b/xCAT-server/lib/xcat/plugins/conserver.pm index 398f4bf2e..03192b37d 100644 --- a/xCAT-server/lib/xcat/plugins/conserver.pm +++ b/xCAT-server/lib/xcat/plugins/conserver.pm @@ -541,7 +541,14 @@ foreach my $node (sort keys %$cfgenthash) { push @$content," master ".$cfgent->{conserver}.";\n"; } else { # handle it here my $locerror = $isSN ? "PERL_BADLANG=0 " : ''; # on service nodes, often LC_ALL is not set and perl complains - push @$content," exec $locerror".$::XCATROOT."/share/xcat/cons/".$cmeth." ".$node.";\n" + + # add XCATSSLVER environment variable when it's set on sles11.x mn + # for cons script to communicate with xcatd through tls + my $env; + if (defined($ENV{'XCATSSLVER'})) { + $env = "XCATSSLVER=$ENV{'XCATSSLVER'} "; + } + push @$content," exec $locerror $env ".$::XCATROOT."/share/xcat/cons/".$cmeth." ".$node.";\n" } } if (defined($cfgent->{consoleondemand})) {