list=> [ 'PVE::API2::LXC', 'vmlist', [], { node => $nodename }, sub {
my $res = shift;
return if !scalar(@$res);
- my $format = "%-10s %-10s %-20s\n";
- printf($format, 'VMID', 'Status', 'Name');
+ my $format = "%-10s %-10s %-12s %-20s\n";
+ printf($format, 'VMID', 'Status', 'Lock', 'Name');
foreach my $d (sort {$a->{vmid} <=> $b->{vmid} } @$res) {
- printf($format, $d->{vmid}, $d->{status}, $d->{name});
+ printf($format, $d->{vmid}, $d->{status}, $d->{lock}, $d->{name});
}
}],
config => [ "PVE::API2::LXC::Config", 'vm_config', ['vmid'],
$d->{cpus} = $conf->{cpulimit} || $cpucount;
+ $d->{lock} = $conf->{lock} || '';
+
if ($d->{pid}) {
my $res = get_container_disk_usage($vmid, $d->{pid});
$d->{disk} = $res->{used};