summaryrefslogtreecommitdiffstats
path: root/configgen
diff options
context:
space:
mode:
authorArne Juul <arnej@yahoo-inc.com>2018-05-14 14:43:04 +0000
committerArne Juul <arnej@yahoo-inc.com>2018-05-14 14:43:25 +0000
commit4503c40245fab0105322110874d01fe379a6b274 (patch)
tree3ea5f886afbeaf1274002f19e905221e3a94adf3 /configgen
parenta9d9ef3dc96791185de550702876d49b1fef9557 (diff)
update perl bootstrap
Diffstat (limited to 'configgen')
-rwxr-xr-xconfiggen/bin/make-config.pl2
-rwxr-xr-xconfiggen/bin/make-configold.pl2
2 files changed, 4 insertions, 0 deletions
diff --git a/configgen/bin/make-config.pl b/configgen/bin/make-config.pl
index 0e116f5eb45..7b1f1f833ab 100755
--- a/configgen/bin/make-config.pl
+++ b/configgen/bin/make-config.pl
@@ -66,9 +66,11 @@ sub findhost {
my $tmp = $ENV{'VESPA_HOSTNAME'};
if (!defined $tmp) {
$tmp = `vespa-detect-hostname` or die "Could not detect hostname\n";
+ chomp $tmp;
}
system("vespa-validate-hostname $tmp");
( $? == 0 ) or die "Could not validate hostname\n";
+ return $tmp;
}
BEGIN {
diff --git a/configgen/bin/make-configold.pl b/configgen/bin/make-configold.pl
index dcba0a02a6d..bbf7322a059 100755
--- a/configgen/bin/make-configold.pl
+++ b/configgen/bin/make-configold.pl
@@ -66,9 +66,11 @@ sub findhost {
my $tmp = $ENV{'VESPA_HOSTNAME'};
if (!defined $tmp) {
$tmp = `vespa-detect-hostname` or die "Could not detect hostname\n";
+ chomp $tmp;
}
system("vespa-validate-hostname $tmp");
( $? == 0 ) or die "Could not validate hostname\n";
+ return $tmp;
}
BEGIN {