}
-unless ($branch =~ /^(HEAD|REL\d+_\d+_STABLE)$/)
-{
- print
- "Status: 492 bad branch parameter $branch\nContent-Type: text/plain\n\n",
- "bad branch parameter $branch\n";
- exit;
-
-}
+# Want to allow all kinds of named branches
+#unless ($branch =~ /^(HEAD|REL\d+_\d+_STABLE)$/)
+#{
+# print
+# "Status: 492 bad branch parameter $branch\nContent-Type: text/plain\n\n",
+# "bad branch parameter $branch\n";
+# exit;
+#
+#}
my $db = DBI->connect($dsn,$dbuser,$dbpass);
--- /dev/null
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+use DBI;
+use Data::Dumper;
+
+use vars qw($dbhost $dbname $dbuser $dbpass $dbport
+);
+require "$ENV{BFConfDir}/BuildFarmWeb.pl";
+
+die "no dbname" unless $dbname;
+die "no dbuser" unless $dbuser;
+
+my $dsn="dbi:Pg:dbname=$dbname";
+$dsn .= ";host=$dbhost" if $dbhost;
+$dsn .= ";port=$dbport" if $dbport;
+
+my $db = DBI->connect($dsn,$dbuser,$dbpass);
+
+die $DBI::errstr unless $db;
+
+my ($brhandle,@branches_of_interest);
+if (open($brhandle,"$ENV{BFConfDir}/htdocs/branches_of_interest.txt"))
+{
+ @branches_of_interest = <$brhandle>;
+ close($brhandle);
+ chomp(@branches_of_interest);
+}
+
+my $sth = $db->prepare(q[
+ SELECT DISTINCT ON (sysname,branch)
+ sysname,branch
+ FROM build_status AS s
+ JOIN buildsystems AS b ON (s.sysname = b.name)
+ ORDER BY sysname, branch ASC
+ ]);
+$sth->execute();
+
+my $del_sth = $db->prepare(q[
+ DELETE FROM build_status
+ WHERE sysname = ?
+ AND branch = ?
+ ]);
+my $del_dash_sth = $db->prepare(q[
+ DELETE FROM dashboard_mat
+ WHERE sysname = ?
+ AND branch = ?
+ ]);
+
+while (my $row = $sth->fetchrow_hashref)
+{
+ my $sysname = $row->{sysname};
+ my $branch = $row->{branch};
+ print "Considering $sysname:$branch\n";
+ unless (grep {$_ eq $branch} @branches_of_interest)
+ {
+ print "** Delete branch $branch\n";
+ $del_sth->execute($sysname,$branch);
+ $del_dash_sth->execute($sysname,$branch);
+ }
+}
+$db->disconnect();
<li id="failures"><a href="/cgi-bin/show_failures.pl" title="Recent Failures">Failures</a></li>
<li id="members"><a href="/cgi-bin/show_members.pl" title="Platforms tested">Members</a></li>
<li id="register"><a href="/cgi-bin/register-form.pl" title="Join Exim BuildFarm">Register</a></li>
- <li id="github"><a href="https://github.com/PGBuildFarm/client-code">GitHub</a></li>
+ <li id="github"><a href="https://github.com/mrballcb/exim-build-farm-client">GitHub</a></li>
<!--
<li id="lists"><a href="http://pgfoundry.org/mail/?group_id=1000040">Email lists and status archives</a></li>
-->
We are particularly interested in unusual platforms or combinations of
architecture, operating system and compiler.
</p>
-<p>To see what is involved in running a buildfarm member, please
-read <a href="http://wiki.exim.org/wiki/Exim_Buildfarm_Howto">http://wiki.exim.org/wiki/Exim_Buildfarm_Howto</a>.
-The client code can be found at the
-<a href="http://eximbuildfarm.mrball.net/downloads/">downloads page</a>.
+<p>To see what is involved in running a buildfarm member, please read the
+<a href="https://github.com/mrballcb/exim-build-farm-client/wiki/Installation">Client Installation</a> instructions.
+Per the instructions, the client code should be checked out with git and
+run using the <strong>run_cron.sh</strong> wrapper script. This will allow
+auto-update of itself when changes are made to the Exim Build Farm Client
+software.
</p>
<p>The build farm software should run on all platforms that can support Exim.
</p>
</div><!-- main -->
<hr />
<p style="text-align: center;">
- Hosting for the Exim Buildfarm is generously
- provided by:
+ The build farm client and server is derived from the excellent
+ <a href="http://buildfarm.postgresql.org">PostgreSQL Build Farm</a>.
+ </p>
+ <p style="text-align: center;">
+ Hosting for the Exim Buildfarm is provided by:
<a href="http://www.mrball.net">Todd Lyons</a>
</p>
</div><!-- wrapper -->
<li id="failures"><a href="/cgi-bin/show_failures.pl" title="Recent Failures">Failures</a></li>
<li id="members"><a href="/cgi-bin/show_members.pl" title="Platforms tested">Members</a></li>
<li id="register"><a href="/cgi-bin/register-form.pl" title="Join Exim BuildFarm">Register</a></li>
- <li id="github"><a href="https://github.com/PGBuildFarm/client-code">GitHub</a></li>
+ <li id="github"><a href="https://github.com/mrballcb/exim-build-farm-client">GitHub</a></li>
<!--
<li id="lists"><a href="http://pgfoundry.org/mail/?group_id=1000040">Email lists and status archives</a></li>
-->
</div><!-- main -->
<hr />
<p style="text-align: center;">
- Hosting for the Exim Buildfarm is generously
- provided by:
+ The build farm client and server is derived from the excellent
+ <a href="http://buildfarm.postgresql.org">PostgreSQL Build Farm</a>.
+ </p>
+ <p style="text-align: center;">
+ Hosting for the Exim Buildfarm is provided by:
<a href="http://www.mrball.net">Todd Lyons</a>
</p>
</div><!-- wrapper -->