207 lines
5.1 KiB
HTML
207 lines
5.1 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta http-equiv="refresh" content="5">
|
|
<title>502 - Backend Unavailable</title>
|
|
<style>
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
body {
|
|
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f0f23 100%);
|
|
color: #a0aec0;
|
|
min-height: 100vh;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 2rem;
|
|
}
|
|
|
|
.container {
|
|
max-width: 600px;
|
|
width: 100%;
|
|
}
|
|
|
|
.content {
|
|
text-align: center;
|
|
}
|
|
|
|
.error-code {
|
|
font-size: 6rem;
|
|
font-weight: 800;
|
|
margin: 0;
|
|
color: #ff6b9d;
|
|
text-shadow: 0 4px 20px #ff6b9d4d;
|
|
line-height: 1;
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
|
|
.title {
|
|
font-size: 2rem;
|
|
font-weight: 600;
|
|
margin: 0.5rem 0;
|
|
color: #ffffff;
|
|
}
|
|
|
|
.message {
|
|
font-size: 1.1rem;
|
|
color: #a0aec0;
|
|
margin: 1rem 0 2rem;
|
|
line-height: 1.6;
|
|
}
|
|
|
|
.info-box {
|
|
background: rgba(255, 255, 255, 0.05);
|
|
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
border-radius: 8px;
|
|
padding: 1.5rem;
|
|
margin-bottom: 1.5rem;
|
|
text-align: left;
|
|
}
|
|
|
|
.info-box h3 {
|
|
color: #ff6b9d;
|
|
font-size: 0.95rem;
|
|
margin-bottom: 0.75rem;
|
|
font-weight: 600;
|
|
}
|
|
|
|
.info-box p {
|
|
color: #a0aec0;
|
|
font-size: 0.95rem;
|
|
line-height: 1.6;
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
|
|
.info-box p:last-child {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
.request-info {
|
|
background: rgba(255, 255, 255, 0.03);
|
|
border: 1px solid rgba(255, 255, 255, 0.05);
|
|
border-radius: 8px;
|
|
padding: 1rem;
|
|
margin-bottom: 1.5rem;
|
|
font-size: 0.875rem;
|
|
text-align: left;
|
|
}
|
|
|
|
.request-info .label {
|
|
color: #6b7280;
|
|
display: inline-block;
|
|
width: 70px;
|
|
}
|
|
|
|
.request-info .value {
|
|
color: #60a5fa;
|
|
word-break: break-all;
|
|
}
|
|
|
|
.request-info div {
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
|
|
.request-info div:last-child {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
.refresh-notice {
|
|
color: #6b7280;
|
|
font-size: 0.75rem;
|
|
text-align: center;
|
|
}
|
|
|
|
.spinner {
|
|
display: inline-block;
|
|
width: 12px;
|
|
height: 12px;
|
|
border: 2px solid rgba(107, 114, 128, 0.3);
|
|
border-top-color: #a0aec0;
|
|
border-radius: 50%;
|
|
animation: spin 1s linear infinite;
|
|
margin-right: 0.5rem;
|
|
vertical-align: middle;
|
|
}
|
|
|
|
@keyframes spin {
|
|
to {
|
|
transform: rotate(360deg);
|
|
}
|
|
}
|
|
|
|
@media (max-width: 768px) {
|
|
.error-code {
|
|
font-size: 4rem;
|
|
}
|
|
|
|
.title {
|
|
font-size: 1.5rem;
|
|
}
|
|
|
|
.message {
|
|
font-size: 1rem;
|
|
}
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="container">
|
|
<div class="content">
|
|
<h1 class="error-code">502</h1>
|
|
<h2 class="title">Backend Unavailable</h2>
|
|
<p class="message">The backend service refused the connection.</p>
|
|
|
|
<div class="info-box">
|
|
<h3>What happened?</h3>
|
|
<p>The backend service isn't running or hasn't finished starting up yet.</p>
|
|
<p>This page will automatically refresh when the service becomes available.</p>
|
|
</div>
|
|
|
|
<div class="request-info">
|
|
<div><span class="label">Host:</span> <span class="value" id="host"><!--# echo var="host" default="unknown" --></span></div>
|
|
<div><span class="label">Path:</span> <span class="value" id="uri"><!--# echo var="request_uri" default="/" --></span></div>
|
|
<div><span class="label">Time:</span> <span class="value" id="time"></span></div>
|
|
</div>
|
|
|
|
<div style="text-align: center; margin-bottom: 1.5rem;">
|
|
<button onclick="window.location.reload()" style="
|
|
background: rgba(255, 107, 157, 0.15);
|
|
border: 1px solid rgba(255, 107, 157, 0.4);
|
|
color: #ff6b9d;
|
|
padding: 0.625rem 1.5rem;
|
|
border-radius: 6px;
|
|
font-size: 0.95rem;
|
|
font-weight: 500;
|
|
cursor: pointer;
|
|
transition: background 0.2s, border-color 0.2s;
|
|
" onmouseover="this.style.background='rgba(255,107,157,0.25)';this.style.borderColor='rgba(255,107,157,0.6)'" onmouseout="this.style.background='rgba(255,107,157,0.15)';this.style.borderColor='rgba(255,107,157,0.4)'">Retry Now</button>
|
|
</div>
|
|
|
|
<div class="refresh-notice">
|
|
<span class="spinner"></span>
|
|
Auto-refreshing every 5 seconds...
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<script>
|
|
document.getElementById('time').textContent = new Date().toLocaleTimeString();
|
|
// Fallback for SSI when not processed
|
|
const host = document.getElementById('host');
|
|
const uri = document.getElementById('uri');
|
|
if (host && host.textContent.includes('echo var')) {
|
|
host.textContent = window.location.hostname;
|
|
}
|
|
if (uri && uri.textContent.includes('echo var')) {
|
|
uri.textContent = window.location.pathname + window.location.search;
|
|
}
|
|
</script>
|
|
</body>
|
|
</html>
|