blob: 85a5ee25bb8e3390fda7473f7b93ce1684dfeb33 [file] [log] [blame]
Alex41485522019-04-12 17:26:18 -05001<!DOCTYPE html>
2<html lang="en">
3<head>
4 <meta charset="UTF-8">
5 <title>Cloud Package versions check</title>
6 {% include 'common_styles.j2' %}
7 {% include 'common_scripts.j2' %}
8 <style>
9 td.repo {width: 3em; text-align: center; font-size: 0.7em; color: #113b11; font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;}
10 td.component, td.app, td.package_name {
11 font-size: 0.75em;
12 text-align: center;
13 color: #113b11;
14 font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
15 }
16
17 td.repo {column-width: 50px;}
18 td.component {column-width: 130px;}
19 td.app {column-width: 80px;}
20 td.package_name {column-width: 200px; padding-left: 10px; text-align: left;}
21 td.node_name {column-width: 210px;}
22 td.installed {column-width: 16%;}
Alex41485522019-04-12 17:26:18 -050023 td.candidate {column-width: 16%;}
24 td.release {column-width: 13%;}
25
26 .status_container {
Alexe9908f72020-05-19 16:04:53 -050027 display: inline-flex;
Alex41485522019-04-12 17:26:18 -050028 }
29
30 .status {
31 display: block;
32 float: left;
33 width: 80px;
34 padding: 1px;
35 padding-left: 5px;
36 padding-right: 5px;
37 color: white;
38 background-color: #113b11;
39 text-align: center;
40 }
41 .action {
42 display: block;
43 float: left;
44 width: 120px;
45 padding: 1px;
46 padding-left: 5px;
47 padding-right: 5px;
48 color: gray;
49 background-color: #d4dad9;
50 text-align: center;
51 }
52
Alexe9908f72020-05-19 16:04:53 -050053 .node {
54 display: block;
55 float: left;
56 width: auto;
57 padding: 1px;
58 padding-left: 2px;
59 padding-right: 2px;
60 margin-left: 3px;
61 border-width: 1px;
62 border-color: gray;
63 border-style: solid;
64 color: gray;
65 background-color: white;
66 text-align: center;
67 }
68
Alex41485522019-04-12 17:26:18 -050069 .status_container .ok {
70 color: white;
71 background-color: #113b11;
72 }
73 .status_container .error {
74 color: white;
75 background-color: darkred;
76 }
77 .status_container .upgraded {
78 color: azure;
79 background-color: green;
80 }
81 .status_container .downgraded {
82 color: white;
83 background-color: darkolivegreen;
84 }
85
86 .status_container .needs_repo {
Alex9e4bfaf2019-06-11 15:21:59 -050087 color: #545454;
88 background-color: #a1b1b0;
Alex41485522019-04-12 17:26:18 -050089 }
90
91 .status_container .needs_up {
92 color: black;
93 background-color: #aaccaa;
94 }
95
96 .status_container .needs_down {
97 color: black;
98 background-color: #ffcc48;
99 }
100
101 .status_container .possible {
102 color: gray;
103 background-color: #d4dad9;
104 }
105
Alexe9908f72020-05-19 16:04:53 -0500106 .status_container .node_error {
107 color: red;
108 border-color: red;
109 background-color: white;
110 }
111
112 .status_container .node_warning {
113 color: olive;
114 border-color: olive;
115 background-color: white;
116 }
117
118 .status_container .node_more {
119 color: gray;
120 border-color: gray;
121 background-color: white;
122 border-style: none;
123 }
124
Alexfa3b0f22019-04-17 16:15:27 -0500125 .status_container .text {
126 width: 500px;
127 font-size: 1em;
128 padding-left: 10px;
129 line-height: 20px;
130 }
131
Alex41485522019-04-12 17:26:18 -0500132
133
134 .version {text-align: left; padding: 2px}
135 .v_epoch, .v_upstream, .v_debian, .colon, .dash {
136 color: darkslategray;
137 float: left;
138 display: block;
139 }
140
141 .ok {color: darkslategray;}
142 .error {color: white; background-color: darkred;}
Alex26b8a8c2019-10-09 17:09:07 -0500143 .warning {color: black; background-color: lightgoldenrodyellow;}
Alex41485522019-04-12 17:26:18 -0500144 .upgraded {color: whitesmoke; background-color: darkslategray;}
145 .downgraded {color: red;}
146
147 .smallgreytext {float: right; font-size: 0.5em; color: gray;}
Alex26b8a8c2019-10-09 17:09:07 -0500148 .tooltiptext { top: 120%; }
Alex41485522019-04-12 17:26:18 -0500149
150 /* Table specific */
151 .nodes tr:nth-child(even) {
152 background-color: #fff;
153 }
154 .nodes tr:nth-child(odd) {
155 background-color: #d4dad9;
156
157 }
158 </style>
159</head>
160<body onload="init()">
161
162<div class="header">
163 <div class="label">OpenStack release:</div>
164 <div class="text">{{ openstack_release }}</div>
165 <div class="label">MCP Version:</div>
166 <div class="text">{{ mcp_release }}</div>
167 <div class="label date">generated on: {{ gen_date }}</div>
168</div>
169
170<div class="bar">
171 <button class="bar-item" onclick="openBar(event, 'mirantis')">Mirantis</button>
172 <button class="bar-item" onclick="openBar(event, 'system')">System</button>
173 <button class="bar-item" onclick="openBar(event, 'other')">Other</button>
174 <button class="bar-item" onclick="openBar(event, 'unlisted')">Unlisted</button>
175 <button class="bar-item" onclick="openBar(event, 'legend')">Legend</button>
176</div>
177
178{% macro prettify_version(v) %}
179 <div class="version">
180 {% if v.epoch %}
Alex836fac82019-08-22 13:36:16 -0500181 <div class="v_epoch {{ v.epoch_status | pkg_status_class }}">{{ v.epoch }}</div>
Alex41485522019-04-12 17:26:18 -0500182 <div class="colon">:</div>
183 {% endif %}
Alex836fac82019-08-22 13:36:16 -0500184 <div class="v_upstream {{ v.upstream_status | pkg_status_class }}">{{ v.upstream }}{{ v.upstream_rev }}</div>
Alex41485522019-04-12 17:26:18 -0500185 {% if v.debian %}
186 <div class="dash">-</div>
Alex836fac82019-08-22 13:36:16 -0500187 <div class="v_debian {{ v.debian_status | pkg_status_class }}">{{ v.debian }}{{ v.debian_rev }}</div>
Alex41485522019-04-12 17:26:18 -0500188 {% endif %}
189 {{ caller() }}
190 </div>
191{% endmacro %}
192
193{% macro render_package(pkg_name, dat, status_shown, action_shown, id_label) %}
194 <tr onclick="toggleClassByID('{{ id_label }}_{{ pkg_name }}_{{ status_shown }}_{{ action_shown }}')" id="{{ id_label }}_{{ pkg_name }}_{{ status_shown }}_{{ action_shown }}_button">
195 <td class="repo">{{ dat['desc']['repo'] }}</td>
Alexd0391d42019-05-21 18:48:55 -0500196 <td class="component">{{ dat['desc']['section'] }}</td>
Alex41485522019-04-12 17:26:18 -0500197 <td class="app">{{ dat['desc']['app'] }}</td>
198 <td class="package_name">{{ pkg_name }}</td>
199 <td class="status_container" colspan="3">
Alex836fac82019-08-22 13:36:16 -0500200 <div class="status {{ status_shown | pkg_status_class }}">{{ status_shown | pkg_status_label }}</div>
201 {% if action_shown | pkg_action_label %}
202 <div class="action {{ action_shown | pkg_action_class }}">{{ action_shown | pkg_action_label }}</div>
Alex41485522019-04-12 17:26:18 -0500203 {% endif %}
Alexe9908f72020-05-19 16:04:53 -0500204 {% set counter = [0] %}
205 {% for status in dat['results'].keys() | sort(reverse=true) %}
206 {% if status_err == status or status_warn == status %}
207 {% for action in dat['results'][status].keys() | sort(reverse=true) %}
208 {% for node in dat['results'][status][action].keys() | sort %}
209 {% if counter.append(counter.pop() + 1) %}{% endif %}
210 {% if counter[0] < 10 %}
211 <div class="node node_{{ status | pkg_status_class }}" alt="{{ counter }}">{{ nodes[node].shortname }}</div>
212 {% endif %}
213 {% endfor %}
214 {% endfor %}
215 {% endif %}
216 {% endfor %}
217
218 {% if counter[0] > 10 %}
219 <div class="node node_more" alt="{{ counter[0]-10 }} more">...</div>
220 {% endif %}
221
Alex41485522019-04-12 17:26:18 -0500222 </td>
223 </tr>
224 <tr class="collapsable" id="{{ id_label }}_{{ pkg_name }}_{{ status_shown }}_{{ action_shown }}"><td colspan="7">
225 <table class="nodes"><tbody>
Alexe9908f72020-05-19 16:04:53 -0500226 {% set counter = [0] %}
Alex41485522019-04-12 17:26:18 -0500227 {% for status in dat['results'].keys() | sort(reverse=true) %}
228 {% for action in dat['results'][status].keys() | sort(reverse=true) %}
Alex41485522019-04-12 17:26:18 -0500229 {% for node in dat['results'][status][action].keys() | sort %}
Alexe9908f72020-05-19 16:04:53 -0500230 {% if counter.append(counter.pop() + 1) %}{% endif %}
Alex41485522019-04-12 17:26:18 -0500231 {% set nd = dat['results'][status][action][node] %}
232 <tr>
Alexe9908f72020-05-19 16:04:53 -0500233 <td class="repo">{{ counter[0] }}</td>
Alex41485522019-04-12 17:26:18 -0500234 <td class="node_name">{{ node }}</td>
235 <td class="status_container">
Alex836fac82019-08-22 13:36:16 -0500236 <div class="status {{ status | pkg_status_class }}">{{ status | pkg_status_label }}</div>
237 {% if action | pkg_action_label %}
238 <div class="action {{ action | pkg_action_class }}">{{ action | pkg_action_label }}</div>
Alex41485522019-04-12 17:26:18 -0500239 {% endif %}
240 </td>
241 <td class="installed">
242 <div class="tooltip">
243 {% call prettify_version(nd['i']) %}
244 <pre class="tooltiptext">{{ nd['raw'] | linebreaks }}</pre>
245 {% endcall %}
246 </div>
247 </td>
248 <td class="candidate">{{ nd['c'].version }}</td>
Alexd0391d42019-05-21 18:48:55 -0500249 <td class="release">
250 <div class="tooltip">
251 {{ dat['r'].version }}
Alex836fac82019-08-22 13:36:16 -0500252 <pre class="repoinfotext">{{ dat['repos'] | pkg_repo_info }}</pre>
Alexd0391d42019-05-21 18:48:55 -0500253 </div>
254 </td>
Alex41485522019-04-12 17:26:18 -0500255 </tr>
256 {% endfor %}
257 {% endfor %}
258 {% endfor %}
259 </tbody></table>
260 </td></tr>
261 {{ caller() }}
262{% endmacro %}
263
264{% macro package_table(pkg_dict, id_label) %}
265<div id="{{ id_label }}" class="barcontent">
266 <h5>{{ caller() }}</h5>
267 <table class="pkgversions">
268 <tbody>
269 <tr>
270 <td class="table_header" width="50px">repo</td>
271 <td class="table_header" width="130px">Component</td>
272 <td class="table_header" width="80px">App</td>
273 <td class="table_header" width="200px">Package name</td>
274 <td class="table_header">Installed</td>
275 <td class="table_header">Candidate</td>
276 <td class="table_header">Release</td>
277 </tr>
278 <!-- Print errors -->
279 <tr><td colspan="7">Errors ({{ errors[id_label] }})</td></tr>
280 {% for pkg_name in pkg_dict | get_sorted_keys %}
281 {% set dat = pkg_dict[pkg_name] %}
282 {% if status_err in dat['results'] %}
283 {% set action_to_show = dat['results'][status_err].keys() | get_max %}
284 {% call render_package(pkg_name, dat, status_err, action_to_show, id_label) %}
285 {% endcall %}
286 {% endif%}
287 {% endfor %}
288 {% if not errors[id_label] %}
289 <tr><td class="note" colspan="7">no errors found </td></tr>
290 {% endif %}
291
Alex26b8a8c2019-10-09 17:09:07 -0500292 <!-- Print warnings -->
293 <tr><td colspan="7">Warnings ({{ warnings[id_label] }})</td></tr>
294 {% for pkg_name in pkg_dict | get_sorted_keys %}
295 {% set dat = pkg_dict[pkg_name] %}
296 {% if status_warn in dat['results'] %}
297 {% set action_to_show = dat['results'][status_warn].keys() | get_max %}
298 {% call render_package(pkg_name, dat, status_warn, action_to_show, id_label) %}
299 {% endcall %}
300 {% endif%}
301 {% endfor %}
302 {% if not warnings[id_label] %}
303 <tr><td class="note" colspan="7">no warnings found </td></tr>
304 {% endif %}
305
Alex41485522019-04-12 17:26:18 -0500306 <!-- Print downgrades -->
307 <tr><td colspan="7">Downgrades ({{ downgrades[id_label] }})</td></tr>
308 {% for pkg_name in pkg_dict | get_sorted_keys %}
309 {% set dat = pkg_dict[pkg_name] %}
310 {% if status_down in dat['results'] %}
311 {% set action_to_show = dat['results'][status_down].keys() | get_max %}
312 {% call render_package(pkg_name, dat, status_down, action_to_show, id_label) %}
313 {% endcall %}
314 {% endif %}
315 {% endfor %}
316 {% if not downgrades[id_label] %}
317 <tr><td class="note" colspan="7">no downgrades found</td></tr>
318 {% endif %}
319
320 <!-- Print all other -->
321 <tr><td colspan="7">All others</td></tr>
322 {% for pkg_name in pkg_dict | get_sorted_keys %}
323 {% set dat = pkg_dict[pkg_name] %}
324 {% set status_to_show = dat['results'].keys() | get_max %}
325 {% set action_to_show = dat['results'][status_to_show].keys() | get_max %}
Alexe65ff4e2019-10-11 14:45:09 -0500326 {% if status_err != status_to_show and status_down != status_to_show and status_warn != status_to_show %}
Alex41485522019-04-12 17:26:18 -0500327 {% call render_package(pkg_name, dat, status_to_show, action_to_show, id_label) %}
328 {% endcall %}
329 {% endif %}
330 {% endfor %}
331 </tbody>
332 </table>
333</div>
334{%- endmacro %}
335
336<!-- Mirantis packages which version is critical for functionality -->
337{% call package_table(critical, "mirantis") %}
338 Packages maintained and updated by Mirantis
339{% endcall %}
340
341<!-- System labeled packages-->
342{% call package_table(system, "system") %}
343 System packages which versions are critical to proper cloud function
344{%- endcall %}
345
346<!-- Other packages -->
347{% call package_table(other, "other") %}
348 Packages with no description or not critical
349{%- endcall %}
350
351{% call package_table(unlisted, "unlisted") %}
352 Packages that are not listed in version map. I.e. unexpected on the environment
353{%- endcall %}
354
355<!-- Legend -->
356<div id="legend" class="barcontent">
Alexfa3b0f22019-04-17 16:15:27 -0500357 <table width="100%"><tbody>
358 <tr>
359 <td width="50%"><h5>Version status desctiptions</h5></td>
360 <td width="50%"><h5>Action descriptions</h5></td>
361 </tr>
362
363 <tr>
364 <td width="50%">
365 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500366 <div class="status {{ cs.ok | pkg_status_class }}">{{ cs.ok | pkg_status_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500367 <div class="text">Installed and Candidate epoch:upstream version mach</div>
368 </div>
369 </td>
370 <td width="50%">
371 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500372 <div class="action {{ ca.na | pkg_action_class }}">{{ ca.na | pkg_action_label }} (no action)</div>
Alexfa3b0f22019-04-17 16:15:27 -0500373 <div class="text">No action suggested</div>
374 </div>
375 </td>
376 </tr>
377 <tr>
378 <td width="50%">
379 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500380 <div class="status {{ cs.up | pkg_status_class }}">{{ cs.up | pkg_status_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500381 <div class="text">Installed version is newer that the one found in Repo (i.e. candidate) or Release notes recordset</div>
382 </div>
383 </td>
384 <td width="50%">
385 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500386 <div class="action {{ ca.up | pkg_action_class }}">{{ ca.up | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500387 <div class="text">There is an upgrade possible for the package. But it is not strictly required action</div>
388 </div>
389 </td>
390 </tr>
391 <tr>
392 <td width="50%">
393 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500394 <div class="status {{ cs.down | pkg_status_class }}">{{ cs.down | pkg_status_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500395 <div class="text">Installed version is older that the one found in Repo (i.e. candidate) or Release notes recordset</div>
396 </div>
397 </td>
398 <td width="50%">
399 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500400 <div class="action {{ ca.need_up | pkg_action_class }}">{{ ca.need_up | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500401 <div class="text">Package should be upgraded to match version either in repo or in Release notes</div>
402 </div>
403 </td>
404 </tr>
405 <tr>
406 <td width="50%">
407 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500408 <div class="status {{ cs.err | pkg_status_class }}">{{ cs.err | pkg_status_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500409 <div class="text">Installed version conflicts with a combination of Candidate and Release notes versions</div>
410 </div>
411 </td>
412 <td width="50%">
413 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500414 <div class="action {{ ca.need_down | pkg_action_class }}">{{ ca.need_down | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500415 <div class="text">Package should be downgraded to match version either in repo or in Release notes</div>
416 </div>
417 </td>
418 </tr>
419 <tr>
420 <td width="50%">
421 </td>
422 <td width="50%">
423 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500424 <div class="action {{ ca.repo | pkg_action_class }}">{{ ca.repo | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500425 <div class="text">Repo that is configured on the target node contains invalid version and should be updated</div>
426 </div>
427 </td>
428 </tr>
429 </tbody></table>
430 <hr>
431 <h5>Versions status and Action combinations</h5>
432 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500433 <div class="status {{ cs.ok | pkg_status_class }}">{{ cs.ok | pkg_status_label }}</div>
434 <div class="action {{ ca.na | pkg_action_class }}">{{ ca.na | pkg_action_label }} (no action)</div>
Alexfa3b0f22019-04-17 16:15:27 -0500435 <div class="text">All versions are inline with each other</div>
436 </div>
437 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500438 <div class="status {{ cs.up | pkg_status_class }}">{{ cs.up | pkg_status_label }}</div>
439 <div class="action {{ ca.na | pkg_action_class }}">{{ ca.na | pkg_action_label }} (no action)</div>
Alexfa3b0f22019-04-17 16:15:27 -0500440 <div class="text">Installed version is newer that Cadidate, Release version - unknown or not tracked</div>
441 </div>
442 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500443 <div class="status {{ cs.ok | pkg_status_class }}">{{ cs.ok | pkg_status_label }}</div>
444 <div class="action {{ ca.up | pkg_action_class }}">{{ ca.up | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500445 <div class="text">Installed version is equal to Release, but there is newer in the repo</div>
446 </div>
447 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500448 <div class="status {{ cs.up | pkg_status_class }}">{{ cs.up | pkg_status_label }}</div>
449 <div class="action {{ ca.up | pkg_action_class }}">{{ ca.up | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500450 <div class="text">Installed version is newer than Release, and there is even newer in the repo</div>
451 </div>
452 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500453 <div class="status {{ cs.err | pkg_status_class }}">{{ cs.err | pkg_status_label }}</div>
454 <div class="action {{ ca.need_up | pkg_action_class }}">{{ ca.need_up | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500455 <div class="text">Installed version is older than Candidate and Release versions and must be upgraded</div>
456 </div>
457 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500458 <div class="status {{ cs.err | pkg_status_class }}">{{ cs.err | pkg_status_label }}</div>
459 <div class="action {{ ca.need_down | pkg_action_class }}">{{ ca.need_down | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500460 <div class="text">Unknown version installed, Release and Candidate versions are older</div>
461 </div>
462 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500463 <div class="status {{ cs.err | pkg_status_class }}">{{ cs.err | pkg_status_label }}</div>
464 <div class="action {{ ca.repo | pkg_action_class }}">{{ ca.repo | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500465 <div class="text">Installed and Candidate versions is older than release and repo must be updated</div>
466 </div>
467
468 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500469 <div class="status {{ cs.up | pkg_status_class }}">{{ cs.up | pkg_status_label }}</div>
470 <div class="action {{ ca.repo | pkg_action_class }}">{{ ca.repo | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500471 <div class="text">Candidate version in repo is older vs Release and both older vs Installed</div>
472 </div>
473 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500474 <div class="status {{ cs.ok | pkg_status_class }}">{{ cs.ok | pkg_status_label }}</div>
475 <div class="action {{ ca.repo | pkg_action_class }}">{{ ca.repo | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500476 <div class="text">Candidate version in Repo is older vs release, but release version installed</div>
477 </div>
478
479 <div class="status_container">
Alex836fac82019-08-22 13:36:16 -0500480 <div class="status {{ cs.down | pkg_status_class }}">{{ cs.down | pkg_status_label }}</div>
481 <div class="action {{ ca.repo | pkg_action_class }}">{{ ca.repo | pkg_action_label }}</div>
Alexfa3b0f22019-04-17 16:15:27 -0500482 <div class="text">Both Candidate in repo and Installed older vs release</div>
483 </div>
484 <div class="status_container">
485
486 <div class="text"></div>
487 </div>
488
Alex41485522019-04-12 17:26:18 -0500489</div>
490</body>
491</html>