aboutsummaryrefslogtreecommitdiffstats
path: root/ulri
diff options
context:
space:
mode:
authorPascal Terjan <pterjan@gmail.com>2015-12-26 18:30:59 +0000
committerPascal Terjan <pterjan@gmail.com>2015-12-26 18:30:59 +0000
commit66b9567910ec50181ed1b89fc89c969a40a853df (patch)
tree11f8e3ee627ed5cedee72ee48dffd601fdfff7d7 /ulri
parenta9ee37d14e6f8f03997dc94bc2f947c10f4356a7 (diff)
downloadiurt-66b9567910ec50181ed1b89fc89c969a40a853df.tar
iurt-66b9567910ec50181ed1b89fc89c969a40a853df.tar.gz
iurt-66b9567910ec50181ed1b89fc89c969a40a853df.tar.bz2
iurt-66b9567910ec50181ed1b89fc89c969a40a853df.tar.xz
iurt-66b9567910ec50181ed1b89fc89c969a40a853df.zip
when failing to send a build to a machine, exclude that machine
Diffstat (limited to 'ulri')
-rwxr-xr-xulri18
1 files changed, 16 insertions, 2 deletions
diff --git a/ulri b/ulri
index b4230c9..4565582 100755
--- a/ulri
+++ b/ulri
@@ -306,6 +306,14 @@ sub done_func {
}
}
+sub exclude_machine {
+ my ($host) = @_;
+ plog('INFO', "Excluding build host $host");
+ foreach my $arch (keys %{$config->{bot}}) {
+ delete $config->{bot}{$arch}{$host};
+ }
+}
+
check_upload_tree($todo, \&todo_func);
# getting already compiled packages
@@ -626,7 +634,10 @@ foreach my $prefix (sort keys %pkg_tree) {
# Copy packages to build node
#
# create also the log dir for botcmd.log
- next if ssh($remote, "mkdir -p $prefix_dir/log");
+ if (ssh($remote, "mkdir -p $prefix_dir/log")) {
+ exclude_machine($host);
+ next;
+ }
my $pkgs;
my $ok = 1;
foreach my $srpm (@$srpms) {
@@ -635,7 +646,10 @@ foreach my $prefix (sort keys %pkg_tree) {
"$prefix_dir/$srpm");
$pkgs .= " $prefix_dir/$srpm";
}
- next unless $ok;
+ if (!$ok) {
+ exclude_machine($host);
+ next;
+ }
# Register that the package is building
$run{bot}{$host}{$bot} = $prefix;