v0.1.26: версия в /health, admin health и UI; ldflags VERSION; Makefile build фикс
This commit is contained in:
+14
-1
@@ -346,7 +346,8 @@ td.msg-expand { padding: 0 !important; border-bottom: 1px solid var(--border); }
|
||||
<div>SQS API: <span style="font-family:monospace">POST /</span> (AWS Signature V4, регион <span style="font-family:monospace">us-east-1</span>)</div>
|
||||
<div>Admin API: <span style="font-family:monospace">POST /admin/tenants</span> (Bearer token)</div>
|
||||
<div>Realm: <span style="font-family:monospace">iot-naeel</span> · Persistence: Managed Redis</div>
|
||||
<div>Образ: <span style="font-family:monospace">naeel/shared-sqs:latest</span></div>
|
||||
<div>Версия: <span id="svc-version" style="font-family:monospace">—</span></div>
|
||||
<div>Образ: <span style="font-family:monospace">naeel/shared-sqs:v0.1.26</span></div>
|
||||
<div style="margin-top:8px;color:var(--warning)">Статус: тестирование</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -496,6 +497,14 @@ let sessionEmail = null; // Email из JWT для отображения в
|
||||
}
|
||||
} catch(e) { /* corrupted — show login */ }
|
||||
}
|
||||
// Версия сервиса — берём из публичного /health и показываем на странице входа
|
||||
fetch(BASE + '/health')
|
||||
.then(r => r.json())
|
||||
.then(h => {
|
||||
const el = document.getElementById('svc-version');
|
||||
if (el && h.version) el.textContent = h.version;
|
||||
})
|
||||
.catch(() => { /* health недоступен — оставляем '—' */ });
|
||||
showLogin();
|
||||
})();
|
||||
|
||||
@@ -619,6 +628,10 @@ function renderDashboard(health, tenants) {
|
||||
<div class="stat-value" style="color:var(--success)">●</div>
|
||||
<div class="stat-label">${health.status || 'ok'}</div>
|
||||
</div>
|
||||
<div class="stat-card">
|
||||
<div class="stat-value" style="font-size:18px">${health.version || 'dev'}</div>
|
||||
<div class="stat-label">Версия</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card">
|
||||
<div class="toolbar">
|
||||
|
||||
Reference in New Issue
Block a user