machines: Read /etc/nix.machines instead of using the BuildMachines table

This commit is contained in:
Shea Levy
2013-03-04 16:03:04 -05:00
parent f9426f365b
commit 170c7c98d0
2 changed files with 9 additions and 22 deletions

View File

@ -56,11 +56,7 @@ sub users : Chained('admin') PathPart('users') Args(0) {
sub machines : Chained('admin') PathPart('machines') Args(0) {
my ($self, $c) = @_;
$c->stash->{machines} = [$c->model('DB::BuildMachines')->search({}, {order_by => "hostname"})];
$c->stash->{systems} = [$c->model('DB::SystemTypes')->search({}, {select => ["system"], order_by => "system" })];
$c->stash->{nixMachines} = nixMachines($c);
$c->stash->{nixMachinesWritable} = (-e "/etc/nix.machines" && -w "/etc/nix.machines");
$c->stash->{machines} = getMachines;
$c->stash->{template} = 'machines.tt';
}