首次提交:初始化项目
This commit is contained in:
193
010-中间件/003-navigation/index.html
Normal file
193
010-中间件/003-navigation/index.html
Normal file
@@ -0,0 +1,193 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>K3s 服务导航</title>
|
||||
<style>
|
||||
* {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
|
||||
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
||||
min-height: 100vh;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.container {
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
header {
|
||||
text-align: center;
|
||||
color: white;
|
||||
margin-bottom: 40px;
|
||||
padding: 40px 20px;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 3em;
|
||||
margin-bottom: 10px;
|
||||
text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
|
||||
}
|
||||
|
||||
.subtitle {
|
||||
font-size: 1.2em;
|
||||
opacity: 0.9;
|
||||
}
|
||||
|
||||
.services-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
|
||||
gap: 20px;
|
||||
margin-bottom: 40px;
|
||||
}
|
||||
|
||||
.service-card {
|
||||
background: white;
|
||||
border-radius: 12px;
|
||||
padding: 25px;
|
||||
box-shadow: 0 10px 30px rgba(0,0,0,0.2);
|
||||
transition: transform 0.3s ease, box-shadow 0.3s ease;
|
||||
text-decoration: none;
|
||||
color: inherit;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.service-card:hover {
|
||||
transform: translateY(-5px);
|
||||
box-shadow: 0 15px 40px rgba(0,0,0,0.3);
|
||||
}
|
||||
|
||||
.service-icon {
|
||||
font-size: 3em;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
||||
.service-name {
|
||||
font-size: 1.5em;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.service-url {
|
||||
color: #667eea;
|
||||
font-size: 0.9em;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.service-description {
|
||||
color: #666;
|
||||
margin-top: 10px;
|
||||
font-size: 0.9em;
|
||||
}
|
||||
|
||||
footer {
|
||||
text-align: center;
|
||||
color: white;
|
||||
padding: 20px;
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
.update-time {
|
||||
background: rgba(255,255,255,0.2);
|
||||
padding: 10px 20px;
|
||||
border-radius: 20px;
|
||||
display: inline-block;
|
||||
margin-top: 20px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<header>
|
||||
<h1>🚀 K3s 服务导航</h1>
|
||||
<p class="subtitle">快速访问您的所有服务</p>
|
||||
</header>
|
||||
|
||||
<div class="services-grid" id="services">
|
||||
<!-- 服务卡片将由 JavaScript 动态生成 -->
|
||||
</div>
|
||||
|
||||
<footer>
|
||||
<div class="update-time">
|
||||
最后更新: <span id="updateTime">加载中...</span>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// 服务配置
|
||||
const services = [
|
||||
{
|
||||
name: 'Longhorn',
|
||||
icon: '💾',
|
||||
url: 'https://longhorn.u6.net3w.com',
|
||||
description: '分布式块存储管理'
|
||||
},
|
||||
{
|
||||
name: 'Grafana',
|
||||
icon: '📊',
|
||||
url: 'https://grafana.u6.net3w.com',
|
||||
description: '监控数据可视化'
|
||||
},
|
||||
{
|
||||
name: 'Prometheus',
|
||||
icon: '📈',
|
||||
url: 'https://prometheus.u6.net3w.com',
|
||||
description: '指标监控系统1'
|
||||
},
|
||||
{
|
||||
name: 'Alertmanager',
|
||||
icon: '🔔',
|
||||
url: 'https://alertmanager.u6.net3w.com',
|
||||
description: '告警管理系统'
|
||||
},
|
||||
{
|
||||
name: 'MinIO S3',
|
||||
icon: '🗄️',
|
||||
url: 'https://s3.u6.net3w.com',
|
||||
description: '对象存储 API'
|
||||
},
|
||||
{
|
||||
name: 'MinIO Console',
|
||||
icon: '🎛️',
|
||||
url: 'https://console.s3.u6.net3w.com',
|
||||
description: 'MinIO 管理控制台'
|
||||
}
|
||||
];
|
||||
|
||||
// 渲染服务卡片
|
||||
function renderServices() {
|
||||
const container = document.getElementById('services');
|
||||
container.innerHTML = services.map(service => `
|
||||
<a href="${service.url}" class="service-card" target="_blank">
|
||||
<div class="service-icon">${service.icon}</div>
|
||||
<div class="service-name">${service.name}</div>
|
||||
<div class="service-url">${service.url}</div>
|
||||
<div class="service-description">${service.description}</div>
|
||||
</a>
|
||||
`).join('');
|
||||
}
|
||||
|
||||
// 更新时间
|
||||
function updateTime() {
|
||||
const now = new Date();
|
||||
document.getElementById('updateTime').textContent = now.toLocaleString('zh-CN');
|
||||
}
|
||||
|
||||
// 初始化
|
||||
renderServices();
|
||||
updateTime();
|
||||
|
||||
// 每分钟更新一次时间
|
||||
setInterval(updateTime, 60000);
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user