1<loader loading="loading"></loader>
2<div class="page overview">
3  <h1 class="page-title inline">{{ dataService.hostname }}</h1>
4  <button class="btn  btn-tertiary" ng-click="edit_hostname = !edit_hostname" aria-label="edit host name">
5    <icon class="nav-icon" aria-hidden="true" file="icon-edit.svg"></icon>
6  </button>
7  <div class="row">
8    <div class="small-12 large-8">
9      <section class="section">
10        <div class="section-header">
11          <h2 class="section-title h3">Server information</h2>
12        </div>
13        <div class="section-content row">
14          <div class="column large-6">
15            <dl class="list-pair">
16              <dt>Model</dt>
17              <dd>{{ server_info.Model  || "N/A"  }}</dd>
18            </dl>
19            <dl class="list-pair">
20              <dt>Serial number</dt>
21              <dd>{{ server_info.SerialNumber || "N/A"  }}</dd>
22            </dl>
23          </div>
24          <div class="column large-6">
25            <dl class="list-pair">
26              <dt>Manufacturer</dt>
27              <dd>{{ server_info.Manufacturer || "N/A" }}</dd>
28            </dl>
29            <dl class="list-pair">
30              <dt>Firmware version</dt>
31              <dd>{{ server_firmware }}</dd>
32            </dl>
33          </div>
34        </div>
35      </section>
36
37      <section class="section">
38        <div class="section-header">
39          <h2 class="section-title h3">BMC information</h2>
40        </div>
41        <div class="section-content row">
42          <div class="column large-6">
43            <dl class="list-pair">
44              <dt>Hostname</dt>
45              <dd class="overview__hostname">
46                {{ dataService.hostname }}
47              </dd>
48            </dl>
49            <dl class="list-pair" ng-repeat="(ifaceName,iface) in dataService.network_interfaces">
50              <dt>{{ifaceName | uppercase}} IP addresses</dt>
51              <dd class="courier-bold" ng-repeat="ipv4 in iface.ipv4.values">
52                IPv4: <span>{{ ipv4.Address }}</span>
53              </dd>
54              <dd class="courier-bold" ng-repeat="ipv6 in iface.ipv6.values">
55                IPv6: <span>{{ ipv6.Address | uppercase }}</span>
56              </dd>
57            </dl>
58          </div>
59          <div class="column large-6">
60            <dl class="list-pair" ng-repeat="(ifaceName,iface) in dataService.network_interfaces">
61              <dt>{{ifaceName | uppercase}} Mac address</dt>
62              <dd>
63                <span>{{iface.MACAddress | uppercase}}</span>
64              </dd>
65            </dl>
66            <dl class="list-pair">
67              <dt>Firmware Version</dt>
68              <dd class="courier-bold">{{ bmc_firmware }}</dd>
69            </dl>
70          </div>
71        </div>
72      </section>
73
74      <section class="section">
75        <div class="section-header">
76          <h2 class="section-title h3">Power Consumption</h2>
77        </div>
78        <div class="section-content row">
79          <div class="column large-6">
80            <dl class="list-pair">
81              <dt>Power Consumption</dt>
82              <dd class="courier-bold">{{ power_consumption }}</dd>
83            </dl>
84          </div>
85          <div class="column large-6">
86            <dl class="list-pair">
87              <dt>Power Cap</dt>
88              <dd class="courier-bold">{{ power_cap }}</dd>
89            </dl>
90          </div>
91        </div>
92      </section>
93    </div>
94    <div class="small-12 large-4">
95      <div class="quick-links">
96        <a href="#/server-health/event-log/high" class="quick-links__item quick-links__events event-log__events"
97          ng-show="logs.length">
98          <!-- link to event log filtered to the high priority events -->
99          <span class="inline quick-links__event-copy">
100            View {{ logs.length }} high priority events
101          </span>
102        </a>
103        <dl class="quick-links__item no-icon">
104          <dt class="inline quick-links__label">BMC time</dt>
105          <dd class="bmc-time">{{ bmc_time | localeDate }}</dd>
106        </dl>
107        <div class="quick-links__item no-icon">
108          <p class="inline quick-links__label">
109            Turn <span ng-if="dataService.LED_state == 'off'">on</span>
110            <span ng-if="dataService.LED_state == 'on'">off</span> server LED
111          </p>
112          <div class="toggle-container">
113            <div class="toggle">
114              <input id="toggle__switch-round" class="toggle-switch toggle-switch__round-flat" type="checkbox"
115                tabindex="0" ng-click="toggleLED()" ng-checked="dataService.LED_state == 'on'"
116                ng-disabled="dataService.server_unreachable" />
117              <label for="toggle__switch-round" tabindex="0">Server LED is
118                <span class="uid-switch__status">{{
119                  dataService.LED_state
120                }}</span></label>
121            </div>
122            <span>
123              {{ dataService.LED_state == "on" ? "On" : "Off" }}
124            </span>
125          </div>
126        </div>
127        <a href="#/server-control/remote-console" class="quick-links__item">
128          <span class="inline quick-links__label">Serial over LAN console</span>
129          <icon aria-hidden="true" file="icon-chevron-right.svg"></icon>
130        </a>
131        <a href="#/configuration/network" class="quick-links__item">
132          <span class="inline quick-links__label">Edit network settings</span>
133          <icon aria-hidden="true" file="icon-chevron-right.svg"></icon>
134        </a>
135      </div>
136    </div>
137  </div>
138
139  <div class="section overview__event-log event-log__events" ng-show="logs.length">
140    <div class="section-header">
141      <h2 class="section-title h3">High priority events ({{ logs.length }})</h2>
142      <a href="#/server-health/event-log/">
143        View all event logs
144      </a>
145    </div>
146
147    <!-- single event -->
148    <a href="#/server-health/event-log/high" ng-repeat="event in logs|orderBy:'-Id'|limitTo : 5">
149      <div class="row column event-log__single-event">
150        <div class="row">
151          <!-- click will go to specific event in event log page-->
152          <div class="column small-10 large-11 event-log__event-info" ng-click="">
153            <div class="row">
154              <div class="column large-1 small-1">
155                <p class="inline event__id">#{{ event.Id }}</p>
156              </div>
157              <div class="column large-4 small-11">
158                <p class="inline event__priority high-priority">High</p>
159                <p class="inline event__severity high-priority">
160                  {{ event.severity_code }}
161                </p>
162              </div>
163              <div class="column large-7 large-offset-0 small-11 small-offset-1">
164                <p class="inline event__timestamp">
165                  {{ event.Timestamp | localeDate }}
166                </p>
167              </div>
168            </div>
169
170            <div class="row">
171              <div class="column large-12 small-11 small-offset-1">
172                <p class="inline event__description">
173                  {{ getEventLogTitle(event) }}
174                </p>
175              </div>
176            </div>
177          </div>
178          <div class="column small-2 large-1">
179            <span class="accord-trigger" aria-hidden="true"></span>
180          </div>
181        </div>
182      </div>
183    </a>
184  </div>
185
186  <div class="section overview__event-log event-log__events" ng-show="!logs.length">
187    <div class="section-header">
188      <h2 class="section-title h3">High priority events</h2>
189    </div>
190    <p class="section-content">
191      There are no high priority events to display at this time.
192    </p>
193  </div>
194</div>
195<!-- edit server name modal -->
196<section class="modal" aria-hidden="true" aria-labelledby="modalTitle" aria-describedby="modalDescription" role="dialog"
197  ng-class="{'active': edit_hostname}">
198  <div class="modal__upload" role="document">
199    <!-- accessibility only; used for screen readers -->
200    <div class="screen-reader-offscreen modal-description">Edit hostname</div>
201    <div class="page-header ">
202      <h2 class="modal-title">
203        <icon class="icon__info" file="icon-information.svg"></icon>Edit
204        hostname
205      </h2>
206    </div>
207    <div class="modal__content">
208      <form name="edit_hostname_text">
209        <label for="editServerName">Hostname</label>
210        <p class="label__helper-text">
211          Hostname must be less than 64 characters and must not contain spaces.
212        </p>
213        <input id="editServerName" class="modal__edit-server-name" type="text" ng-model="newHostname" ng-trim="false"
214          name="hostname" ng-pattern="/^\S{0,64}$/" required autofocus />
215        <span class="modal__error" ng-show="edit_hostname_text.hostname.$error.pattern">Invalid format. Remove
216          spaces.</span>
217        <span class="modal__char-count"
218          ng-hide="edit_hostname_text.hostname.$error.pattern">{{ 0 + newHostname.length }}/64</span>
219      </form>
220    </div>
221    <div class="modal__button-wrapper">
222      <button class="btn  btn-secondary" ng-click="edit_hostname= false; newHostname = dataService.hostname">
223        Cancel
224      </button>
225      <button class="btn  btn-primary" ng-click="saveHostname(newHostname);" ng-disabled="edit_hostname_text.$invalid"
226        ng-class="{'disabled' : edit_hostname_text.$invalid}">
227        Save
228      </button>
229    </div>
230  </div>
231</section>
232<div class="modal-overlay" tabindex="-1" ng-class="{'active': edit_hostname}"></div>
233