Machine status page: Show disabled machines and some machine stats
[?]
Sep 9, 2015, 2:51 PM
NX5BM2OINIVVOHN23N2DWH5LHVQN7AVRWYPUZ5J54WXFWE5B5XIQCDependencies
- [2]
2MSFKTD5Ensure proper encoding of error messages - [3]
AXU7D4PDMachine status page: Add link to build step - [4]
TASNW7CTRemove double entry for localhost on machines status page - [5]
RFGPN7U7Machine status: Don't show removed machines anymore - [6]
36ZTCZ4FAdd basic Persona support - [7]
V6S6OYIAFormatting tweaks - [8]
J4R2VCPPFix showing build steps in the machine status page - [9]
UFFPFIXSDon't show how long a machine has been idle - [10]
HTL6HIBMmachine-status: Read /etc/nix.machines instead of using the BuildMachines table - [*]
J5UVLXOK* Start of a basic Catalyst web interface. - [*]
SMM4HQTP* Put actions related to builds under /build (e.g. /log/<buildid> - [*]
ZWCTAZGLadded newsitems, added some admin options to clear various caches.
Change contents
- edit in src/lib/Hydra/Controller/Root.pm at line 12
use JSON; - replacement in src/lib/Hydra/Controller/Root.pm at line 113
${$machines}{''} //= {};delete ${$machines}{'localhost'};$machines->{''} //= {};delete $machines->{'localhost'};my $status = $c->model('DB::SystemStatus')->find("queue-runner");if ($status) {my $ms = decode_json($status->status)->{"machines"};foreach my $name (keys %{$ms}) {$name = "" if $name eq "localhost";$machines->{$name} //= {disabled => 1};$machines->{$name}->{nrStepsDone} = $ms->{$name}->{nrStepsDone};$machines->{$name}->{avgStepBuildTime} = $ms->{$name}->{avgStepBuildTime} // 0;}} - edit in src/root/machine-status.tt at line 3[14.8411][14.9392]
[% USE format %] - replacement in src/root/machine-status.tt at line 21
<tt>[% name %]</tt><tt [% IF m.value.disabled %]style="text-decoration: line-through;"[% END %]>[% name %]</tt> - replacement in src/root/machine-status.tt at line 23
([% comma=0; FOREACH system IN m.value.systemTypes %][% IF comma; %], [% ELSE; comma = 1; END %]<tt>[% system %]</tt>[% END %])<span class="muted" style="font-weight: normal;">([% comma=0; FOREACH system IN m.value.systemTypes %][% IF comma; %], [% ELSE; comma = 1; END %]<tt>[% system %]</tt>[% END %])</span>[% END %][% IF m.value.nrStepsDone %]<span class="muted" style="font-weight: normal;">([% m.value.nrStepsDone %] steps done, [% f = format("%.1f"); f(m.value.avgStepBuildTime) %] s/step)</span>