mirror of https://github.com/nicolargo/glances
Manage the all option (in the Vms plugin)
parent
8e4b9d9215
commit
c9525b8a5a
|
@ -465,8 +465,8 @@ port_default_gateway=True
|
||||||
disable=False
|
disable=False
|
||||||
# Define the maximum VMs size name (default is 20 chars)
|
# Define the maximum VMs size name (default is 20 chars)
|
||||||
max_name_size=20
|
max_name_size=20
|
||||||
# By default, Glances only display running VMs
|
# By default, Glances only display running VMs with states: 'Running', 'Starting' or 'Restarting'
|
||||||
# Set the following key to True to display all VMs
|
# Set the following key to True to display all VMs regarding their states
|
||||||
all=False
|
all=False
|
||||||
|
|
||||||
[containers]
|
[containers]
|
||||||
|
|
|
@ -103,7 +103,7 @@ class VmExtension:
|
||||||
for k, v in info_stats.items():
|
for k, v in info_stats.items():
|
||||||
# Only display when VM in on 'running' states
|
# Only display when VM in on 'running' states
|
||||||
# See states list here: https://multipass.run/docs/instance-states
|
# See states list here: https://multipass.run/docs/instance-states
|
||||||
if self._want_display(v, 'state', ['Running', 'Starting', 'Restarting']):
|
if all_tag or self._want_display(v, 'state', ['Running', 'Starting', 'Restarting']):
|
||||||
returned_stats.append(self.generate_stats(k, v))
|
returned_stats.append(self.generate_stats(k, v))
|
||||||
|
|
||||||
return version_stats, returned_stats
|
return version_stats, returned_stats
|
||||||
|
|
Loading…
Reference in New Issue