Skip to content

Commit

Permalink
fix: brings back labels CPU and bases CPU on one core. See #2944 (#2945)
Browse files Browse the repository at this point in the history
  • Loading branch information
amir20 committed May 12, 2024
1 parent e09aeb4 commit 4b04659
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions assets/components/ContainerTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -76,14 +76,20 @@
<distance-time :date="container.created" strict :suffix="false"></distance-time>
</td>
<td v-if="isVisible('cpu')">
<progress
class="progress progress-primary"
:value="container.movingAverage.cpu"
:max="100 * hosts[container.host].nCPU"
></progress>
<div class="flex flex-row items-center gap-1">
<progress
class="progress progress-primary"
:value="Math.min(container.movingAverage.cpu, 100)"
:max="100"
></progress>
<span class="text-sm">{{ container.movingAverage.cpu.toFixed(0) }}%</span>
</div>
</td>
<td v-if="isVisible('mem')">
<progress class="progress progress-primary" :value="container.movingAverage.memory" max="100"></progress>
<div class="flex flex-row items-center gap-1">
<progress class="progress progress-primary" :value="container.movingAverage.memory" max="100"></progress>
<span class="text-sm">{{ container.movingAverage.memory.toFixed(0) }}%</span>
</div>
</td>
</tr>
</tbody>
Expand Down

0 comments on commit 4b04659

Please sign in to comment.