github.com/hernad/nomad@v1.6.112/ui/app/templates/components/plugin-allocation-row.hbs (about) 1 {{! 2 Copyright (c) HashiCorp, Inc. 3 SPDX-License-Identifier: MPL-2.0 4 ~}} 5 6 {{#if this.allocation}} 7 <td data-test-indicators class="is-narrow"> 8 {{#if this.allocation.unhealthyDrivers.length}} 9 <span data-test-icon="unhealthy-driver" class="tooltip text-center" role="tooltip" aria-label="Allocation depends on unhealthy drivers"> 10 {{x-icon "alert-triangle" class="is-warning"}} 11 </span> 12 {{/if}} 13 {{#if this.allocation.nextAllocation}} 14 <span data-test-icon="reschedule" class="tooltip text-center" role="tooltip" aria-label="Allocation was rescheduled"> 15 {{x-icon "history" class="is-faded"}} 16 </span> 17 {{/if}} 18 {{#if this.allocation.wasPreempted}} 19 <span data-test-icon="preemption" class="tooltip text-center" role="tooltip" aria-label="Allocation was preempted"> 20 {{x-icon "boot" class="is-faded"}} 21 </span> 22 {{/if}} 23 </td> 24 25 <td data-test-short-id> 26 <LinkTo @route="allocations.allocation" @model={{this.allocation}} class="is-primary"> 27 {{this.allocation.shortId}} 28 </LinkTo> 29 </td> 30 31 <td data-test-create-time> 32 <span class="tooltip" aria-label="{{format-month-ts this.allocation.createTime}}"> 33 {{format-month-ts this.allocation.createTime short=true}} 34 </span> 35 </td> 36 37 <td data-test-modify-time> 38 <span class="tooltip" aria-label="{{format-month-ts this.allocation.modifyTime}}"> 39 {{moment-from-now this.allocation.modifyTime}} 40 </span> 41 </td> 42 43 <td data-test-health> 44 <span class="nowrap"> 45 {{x-icon 46 (if this.pluginAllocation.healthy "check-circle-outline" "minus-circle-outline") 47 class=(if this.pluginAllocation.healthy "is-success" "is-danger")}} 48 {{if this.pluginAllocation.healthy "Healthy" "Unhealthy"}} 49 </span> 50 </td> 51 52 <td data-test-client> 53 <Tooltip @text={{this.allocation.node.name}}> 54 <LinkTo @route="clients.client" @model={{this.allocation.node}}> 55 {{this.allocation.node.shortId}} 56 </LinkTo> 57 </Tooltip> 58 </td> 59 <td> 60 {{#if (or this.allocation.job.isPending this.allocation.job.isReloading)}} 61 ... 62 {{else}} 63 <LinkTo @route="jobs.job" @model={{this.allocation.job}} data-test-job>{{this.allocation.job.name}}</LinkTo> 64 <span class="is-faded" data-test-task-group>/ {{this.allocation.taskGroup.name}}</span> 65 {{/if}} 66 </td> 67 <td data-test-job-version class="is-1">{{this.allocation.jobVersion}}</td> 68 <td data-test-volume>{{if this.allocation.taskGroup.volumes.length "Yes"}}</td> 69 70 <td data-test-cpu class="is-1 has-text-centered"> 71 <AllocationStat 72 @metric="cpu" 73 @allocation={{this.allocation}} 74 @statsTracker={{this.stats}} 75 @isLoading={{this.fetchStats.isRunning}} 76 @error={{this.statsError}} /> 77 </td> 78 <td data-test-mem class="is-1 has-text-centered"> 79 <AllocationStat 80 @metric="memory" 81 @allocation={{this.allocation}} 82 @statsTracker={{this.stats}} 83 @isLoading={{this.fetchStats.isRunning}} 84 @error={{this.statsError}} /> 85 </td> 86 {{else}} 87 <td colspan="10">…</td> 88 {{/if}}