mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-14 20:01:09 +02:00
feat(manascore): add live uptime badges from status.mana.how
- generate-status-page.sh now also writes status.json alongside index.html
Format: { updated, summary: {up, total}, services: { appName: bool } }
- nginx status.mana.how serves status.json with CORS headers (public read)
and explicit location block to avoid rewrite to index.html
- ManaScore index page fetches status.json client-side on load and
injects green ● LIVE / red ● DOWN badge next to each app's status chip
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
259253e7b3
commit
08032c004b
3 changed files with 62 additions and 0 deletions
|
|
@ -118,10 +118,22 @@ server {
|
|||
add_header X-Content-Type-Options "nosniff" always;
|
||||
add_header Cache-Control "no-store" always;
|
||||
|
||||
# Allow ManaScore page to fetch status.json
|
||||
add_header Access-Control-Allow-Origin "*" always;
|
||||
add_header Access-Control-Allow-Methods "GET" always;
|
||||
|
||||
location / {
|
||||
try_files $uri /index.html;
|
||||
}
|
||||
|
||||
# Serve status.json directly (do not rewrite to index.html)
|
||||
location = /status.json {
|
||||
add_header Content-Type "application/json" always;
|
||||
add_header Cache-Control "no-store" always;
|
||||
add_header Access-Control-Allow-Origin "*" always;
|
||||
try_files $uri =404;
|
||||
}
|
||||
|
||||
location /health {
|
||||
access_log off;
|
||||
return 200 "healthy\n";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue