mirror of https://github.com/nicolargo/glances.git
Correct some issues concerning #1985: make the podman object serializable, update the webui, update the documentation
This commit is contained in:
parent
e3a1a774ca
commit
2ae676ba12
|
|
@ -127,10 +127,10 @@
|
|||
</div>
|
||||
</div>
|
||||
<div class="col-sm-18">
|
||||
<glances-plugin-docker
|
||||
v-if="!args.disable_docker"
|
||||
<glances-plugin-containers
|
||||
v-if="!args.disable_containers"
|
||||
:data="data"
|
||||
></glances-plugin-docker>
|
||||
></glances-plugin-containers>
|
||||
<glances-plugin-process :data="data"></glances-plugin-process>
|
||||
<glances-plugin-alert
|
||||
v-if="!args.disable_alert"
|
||||
|
|
@ -153,7 +153,7 @@ import GlancesPluginCloud from './components/plugin-cloud.vue';
|
|||
import GlancesPluginConnections from './components/plugin-connections.vue';
|
||||
import GlancesPluginCpu from './components/plugin-cpu.vue';
|
||||
import GlancesPluginDiskio from './components/plugin-diskio.vue';
|
||||
import GlancesPluginDocker from './components/plugin-docker.vue';
|
||||
import GlancesPluginContainers from './components/plugin-containers.vue';
|
||||
import GlancesPluginFolders from './components/plugin-folders.vue';
|
||||
import GlancesPluginFs from './components/plugin-fs.vue';
|
||||
import GlancesPluginGpu from './components/plugin-gpu.vue';
|
||||
|
|
@ -183,7 +183,7 @@ export default {
|
|||
GlancesPluginConnections,
|
||||
GlancesPluginCpu,
|
||||
GlancesPluginDiskio,
|
||||
GlancesPluginDocker,
|
||||
GlancesPluginContainers,
|
||||
GlancesPluginFolders,
|
||||
GlancesPluginFs,
|
||||
GlancesPluginGpu,
|
||||
|
|
@ -241,37 +241,37 @@ export default {
|
|||
},
|
||||
methods: {
|
||||
setupHotKeys() {
|
||||
// a => Sort processes/docker automatically
|
||||
// a => Sort processes/containers automatically
|
||||
hotkeys('a', () => {
|
||||
this.store.args.sort_processes_key = null;
|
||||
});
|
||||
|
||||
// c => Sort processes/docker by CPU%
|
||||
// c => Sort processes/containers by CPU%
|
||||
hotkeys('c', () => {
|
||||
this.store.args.sort_processes_key = 'cpu_percent';
|
||||
});
|
||||
|
||||
// m => Sort processes/docker by MEM%
|
||||
// m => Sort processes/containers by MEM%
|
||||
hotkeys('m', () => {
|
||||
this.store.args.sort_processes_key = 'memory_percent';
|
||||
});
|
||||
|
||||
// u => Sort processes/docker by user
|
||||
// u => Sort processes/containers by user
|
||||
hotkeys('u', () => {
|
||||
this.store.args.sort_processes_key = 'username';
|
||||
});
|
||||
|
||||
// p => Sort processes/docker by name
|
||||
// p => Sort processes/containers by name
|
||||
hotkeys('p', () => {
|
||||
this.store.args.sort_processes_key = 'name';
|
||||
});
|
||||
|
||||
// i => Sort processes/docker by I/O rate
|
||||
// i => Sort processes/containers by I/O rate
|
||||
hotkeys('i', () => {
|
||||
this.store.args.sort_processes_key = 'io_counters';
|
||||
});
|
||||
|
||||
// t => Sort processes/docker by time
|
||||
// t => Sort processes/containers by time
|
||||
hotkeys('t', () => {
|
||||
this.store.args.sort_processes_key = 'timemillis';
|
||||
});
|
||||
|
|
@ -331,9 +331,9 @@ export default {
|
|||
this.store.args.process_short_name = !this.store.args.process_short_name;
|
||||
});
|
||||
|
||||
// D => Enable/disable Docker stats
|
||||
// D => Enable/disable containers stats
|
||||
hotkeys('shift+D', () => {
|
||||
this.store.args.disable_docker = !this.store.args.disable_docker;
|
||||
this.store.args.disable_containers = !this.store.args.disable_containers;
|
||||
});
|
||||
|
||||
// b => Bytes or bits for network I/O
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@
|
|||
{{ help.sort_io_rate }}
|
||||
</div>
|
||||
<div class="divTableCell">
|
||||
{{ help.show_hide_docker }}
|
||||
{{ help.show_hide_containers }}
|
||||
</div>
|
||||
<div class="divTableCell">
|
||||
{{ help.toggle_used_free }}
|
||||
|
|
|
|||
|
|
@ -4,6 +4,8 @@
|
|||
{{ containers.length }} sorted by {{ sorter.getColumnLabel(sorter.column) }}
|
||||
<div class="table">
|
||||
<div class="table-row">
|
||||
<div class="table-cell text-left">Engine</div>
|
||||
<div class="table-cell text-left">Pod</div>
|
||||
<div
|
||||
class="table-cell text-left"
|
||||
:class="['sortable', sorter.column === 'name' && 'sort']"
|
||||
|
|
@ -39,6 +41,8 @@
|
|||
v-for="(container, containerId) in containers"
|
||||
:key="containerId"
|
||||
>
|
||||
<div class="table-cell text-left">{{ container.engine }}</div>
|
||||
<div class="table-cell text-left">{{ container.pod_id || '-' }}</div>
|
||||
<div class="table-cell text-left">{{ container.name }}</div>
|
||||
<div class="table-cell" :class="container.status == 'Paused' ? 'careful' : 'ok'">
|
||||
{{ container.status }}
|
||||
|
|
@ -99,7 +103,7 @@ export default {
|
|||
return this.args.sort_processes_key;
|
||||
},
|
||||
stats() {
|
||||
return this.data.stats['docker'];
|
||||
return this.data.stats['containers'];
|
||||
},
|
||||
containers() {
|
||||
const { sorter } = this;
|
||||
|
|
@ -120,7 +124,9 @@ export default {
|
|||
'tx': containerData.network.tx != undefined ? containerData.network.tx : '?',
|
||||
'net_time_since_update': containerData.network.time_since_update,
|
||||
'command': containerData.Command.join(' '),
|
||||
'image': containerData.Image
|
||||
'image': containerData.Image,
|
||||
'engine': containerData.engine,
|
||||
'pod_id': containerData.pod_id
|
||||
};
|
||||
});
|
||||
return orderBy(
|
||||
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue