From 43a09748855e234377ddbff60871e39809fa61a9 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 9 Mar 2015 12:16:52 -0400 Subject: [PATCH] cr-ensure-disk-space: Take argument for what to clean Currently always "LogsPublish" (so no functional change). Signed-off-by: Ian Jackson --- cr-ensure-disk-space | 7 +++++-- cri-args-hostlists | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/cr-ensure-disk-space b/cr-ensure-disk-space index af8efe6..884be26 100755 --- a/cr-ensure-disk-space +++ b/cr-ensure-disk-space @@ -36,7 +36,9 @@ while (@ARGV && $ARGV[0] =~ m/^\-/) { } } -die if @ARGV; +die unless @ARGV==1; + +our ($cfgbase) = @ARGV; csreadconfig(); @@ -50,7 +52,8 @@ my $chkq= $dbh_tests->prepare("SELECT * FROM flights WHERE flight=?"); our @flights; our @sshopts= qw(-o batchmode=yes); -$c{LogsPublish} =~ m/\:/ or die "$c{LogsPublish} ?"; +my $cfgvalue = $c{$cfgbase}; +$cgvvalue =~ m/\:/ or die "$c{LogsPublish} ?"; my ($pubhost, $pubdir) = ($`,$'); #'; sub ontarget ($) { diff --git a/cri-args-hostlists b/cri-args-hostlists index 2ee0b7b..11f01bd 100644 --- a/cri-args-hostlists +++ b/cri-args-hostlists @@ -74,7 +74,7 @@ execute_flight () { rm -f abort check_stop_core '' - ./cr-ensure-disk-space + ./cr-ensure-disk-space LogsPublish export OSSTEST_RESOURCE_PREINFO="[$branch $2]" -- 2.39.5