2021-11-05 17:46:41 +00:00
|
|
|
{{#if (eq @item.Datacenter '')}}
|
|
|
|
<a
|
|
|
|
class="topology-metrics-card"
|
|
|
|
href={{href-to 'dc.services.index'}}
|
|
|
|
data-permission={{service/card-permissions @item}}
|
|
|
|
>
|
2021-04-13 16:17:53 +00:00
|
|
|
<p class="empty">
|
|
|
|
{{@item.Name}}
|
|
|
|
</p>
|
|
|
|
</a>
|
|
|
|
{{else}}
|
2021-08-26 17:58:06 +00:00
|
|
|
<a data-test-topology-metrics-card
|
|
|
|
class="topology-metrics-card"
|
2020-11-24 14:33:34 +00:00
|
|
|
href={{if
|
|
|
|
(and (env 'CONSUL_NSPACES_ENABLED') (not-eq @item.Namespace @service.Namespace))
|
2021-08-26 17:58:06 +00:00
|
|
|
(href-to this.hrefPath @item.Datacenter @item.Name params=(hash nspace=@item.Namespace))
|
|
|
|
(href-to this.hrefPath @item.Name)
|
2020-11-24 14:33:34 +00:00
|
|
|
}}
|
2021-11-05 17:46:41 +00:00
|
|
|
data-permission={{service/card-permissions @item}}
|
2020-11-12 15:40:15 +00:00
|
|
|
id="{{@item.Namespace}}{{@item.Name}}"
|
2020-10-09 20:31:15 +00:00
|
|
|
>
|
|
|
|
<p>
|
2020-11-12 15:40:15 +00:00
|
|
|
{{@item.Name}}
|
2020-10-09 20:31:15 +00:00
|
|
|
</p>
|
2021-04-08 19:14:53 +00:00
|
|
|
{{#if (eq @item.Source 'proxy-registration')}}
|
2021-08-26 17:58:06 +00:00
|
|
|
<TopologyMetrics::SourceType @source='proxy-registration' />
|
|
|
|
{{/if}}
|
|
|
|
{{#if (eq @item.Source 'routing-config')}}
|
|
|
|
<TopologyMetrics::SourceType @source='routing-config' />
|
2021-04-08 19:14:53 +00:00
|
|
|
{{/if}}
|
2020-10-09 20:31:15 +00:00
|
|
|
<div class="details">
|
2020-11-19 18:40:05 +00:00
|
|
|
{{#if (and (env 'CONSUL_NSPACES_ENABLED') (not-eq @item.Namespace @service.Namespace))}}
|
2020-10-09 20:31:15 +00:00
|
|
|
<dl class="nspace">
|
|
|
|
<dt>
|
|
|
|
<Tooltip>
|
|
|
|
Namespace
|
|
|
|
</Tooltip>
|
|
|
|
</dt>
|
|
|
|
<dd>
|
2020-11-12 15:40:15 +00:00
|
|
|
{{@item.Namespace}}
|
2020-10-09 20:31:15 +00:00
|
|
|
</dd>
|
|
|
|
</dl>
|
|
|
|
{{/if}}
|
2021-08-26 17:58:06 +00:00
|
|
|
|
|
|
|
{{#if (not-eq @item.Source 'routing-config')}}
|
|
|
|
|
2020-11-12 15:40:15 +00:00
|
|
|
{{#if (eq @item.Datacenter @dc)}}
|
|
|
|
{{#let (service/health-percentage @item) as |percentage|}}
|
2020-12-15 19:32:03 +00:00
|
|
|
{{#if (eq percentage '')}}
|
|
|
|
<span class="empty">No health checks</span>
|
|
|
|
{{else}}
|
2020-10-09 20:31:15 +00:00
|
|
|
{{#if (not-eq percentage.passing 0)}}
|
|
|
|
<span class="passing">{{percentage.passing}}%</span>
|
|
|
|
{{/if}}
|
|
|
|
{{#if (not-eq percentage.warning 0)}}
|
|
|
|
<span class="warning">{{percentage.warning}}%</span>
|
|
|
|
{{/if}}
|
|
|
|
{{#if (not-eq percentage.critical 0)}}
|
|
|
|
<span class="critical">{{percentage.critical}}%</span>
|
|
|
|
{{/if}}
|
2020-12-15 19:32:03 +00:00
|
|
|
{{/if}}
|
2020-10-09 20:31:15 +00:00
|
|
|
{{/let}}
|
|
|
|
{{else}}
|
|
|
|
<dl class="health">
|
|
|
|
<dt>
|
|
|
|
<Tooltip>
|
|
|
|
We are unable to determine the health status of services in remote datacenters.
|
|
|
|
</Tooltip>
|
|
|
|
</dt>
|
|
|
|
<dd>
|
|
|
|
Health
|
|
|
|
</dd>
|
|
|
|
</dl>
|
2021-08-26 17:58:06 +00:00
|
|
|
{{/if}}
|
|
|
|
|
2020-10-09 20:31:15 +00:00
|
|
|
{{/if}}
|
|
|
|
</div>
|
2020-12-08 15:47:55 +00:00
|
|
|
{{yield}}
|
2021-04-13 16:17:53 +00:00
|
|
|
</a>
|
|
|
|
{{/if}}
|