fix: replace internal runtime terms in visible UI
Some checks failed
CD Pipeline / deploy (push) Failing after 1m4s

This commit is contained in:
ogt
2026-06-25 12:48:23 +08:00
parent 9618cf237f
commit deb771d6f7
15 changed files with 96 additions and 55 deletions

View File

@@ -80,7 +80,7 @@
font-weight: 800;
}
/* Pipeline Flow */
/* 部署流程 */
.pipeline-flow {
display: flex;
align-items: center;
@@ -200,7 +200,7 @@
.pod-status .pod-ready.healthy { background: rgba(40, 167, 69, 0.3); }
.pod-status .pod-ready.unhealthy { background: rgba(220, 53, 69, 0.3); }
/* Pipeline History */
/* 部署歷史 */
.pipeline-item {
display: flex;
align-items: center;
@@ -524,7 +524,7 @@
</div>
</div>
<!-- Pipeline Flow -->
<!-- 部署流程 -->
<div class="card mb-4">
<div class="card-header d-flex justify-content-between align-items-center">
<span><i class="bi bi-diagram-3 me-2"></i>最新部署流程</span>
@@ -617,7 +617,7 @@
<i class="bi bi-search me-1"></i>診斷
</button>
<button class="btn btn-sm btn-outline-info" onclick="triggerFullRepair()">
<i class="bi bi-wrench me-1"></i>一鍵修復
<i class="bi bi-wrench me-1"></i>修復部署
</button>
</div>
</div>
@@ -625,12 +625,12 @@
</div>
</div>
<!-- Pipeline History -->
<!-- 部署歷史 -->
<div class="card mb-4">
<div class="card-header d-flex justify-content-between align-items-center">
<span><i class="bi bi-clock-history me-2"></i>部署歷史</span>
<a href="http://192.168.0.110:8929/root/momo-pro-system/-/pipelines" target="_blank" class="btn btn-sm btn-outline-light">
查看
查看部署紀錄
</a>
</div>
<div class="card-body" id="pipelineHistory">
@@ -963,7 +963,7 @@
// 渲染 runtime 狀態
function renderPods(pods, envId) {
if (!pods || pods.length === 0) {
return '<p class="text-muted small mb-0">Docker Compose 執行環境;叢集資訊不適用</p>';
return '<p class="text-muted small mb-0">Docker Compose 執行環境;外部叢集資訊不適用</p>';
}
return pods.map(pod => `
@@ -1098,7 +1098,7 @@
}
}
// 完整修復
// 部署修復
async function triggerFullRepair() {
const env = prompt('請輸入要修復的環境 (uat 或 prod):', 'uat');
if (!env || !['uat', 'prod'].includes(env)) {
@@ -1106,9 +1106,9 @@
return;
}
if (!confirm(`確定要對 ${env.toUpperCase()} 執行完整修復嗎?\n這會重啟 Registry 並執行執行環境診斷,不會重啟舊叢集`)) return;
if (!confirm(`確定要對 ${env.toUpperCase()} 執行部署修復嗎?\n這會執行必要服務修復與環境診斷`)) return;
showNotification('執行中', '正在執行完整修復...');
showNotification('執行中', '正在修復部署狀態...');
try {
const response = await fetch('/api/cicd/auto-fix', {
@@ -1120,13 +1120,13 @@
const data = await response.json();
if (data.success) {
showNotification('✅ 完整修復完成', `已執行 ${data.results?.length || 0} 個修復動作`);
showNotification('✅ 部署修復完成', `已執行 ${data.results?.length || 0} 個修復動作`);
setTimeout(loadDashboard, 5000);
} else {
showNotification('❌ 修復失敗', data.error, true);
}
} catch (error) {
showNotification('❌ 錯誤', '無法執行完整修復: ' + error, true);
showNotification('❌ 錯誤', '無法執行部署修復: ' + error, true);
}
}