Initial import: nasmon health monitor, split out of home_nas
Go service (nasmon/) plus nfpm packaging (packaging/), carried over from the home_nas monorepo. Adds rpm packaging alongside the existing deb build (Fedora/RHEL/Rocky dependency names via nfpm overrides, per-format systemd unit path, dpkg+rpm-compatible maintainer scripts) and a Gitea Actions workflow that builds both formats on every push. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
{{define "layout"}}<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>{{.Title}} · nasmon</title>
|
||||
<link rel="stylesheet" href="/static/app.css">
|
||||
<link rel="icon" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Crect width='16' height='16' rx='3' fill='%232d7ff9'/%3E%3C/svg%3E">
|
||||
</head>
|
||||
<body data-page="{{.Page}}">
|
||||
<header class="top">
|
||||
<a class="brand" href="/">nasmon</a>
|
||||
<nav>
|
||||
<a href="/" {{if eq .Page "dashboard"}}class="on"{{end}}>Dashboard</a>
|
||||
<a href="/zfs" {{if eq .Page "zfs"}}class="on"{{end}}>ZFS</a>
|
||||
<a href="/shares" {{if eq .Page "shares"}}class="on"{{end}}>Shares</a>
|
||||
<a href="/alerts" {{if eq .Page "alerts"}}class="on"{{end}}>Alerts{{if .Alerts}} <span class="badge crit">{{.Alerts}}</span>{{end}}</a>
|
||||
<a href="/settings" {{if eq .Page "settings"}}class="on"{{end}}>Settings</a>
|
||||
</nav>
|
||||
<span class="refresh" id="refresh-state" title="auto-refresh"></span>
|
||||
</header>
|
||||
<main id="content">{{template "content" .}}</main>
|
||||
<script src="/static/app.js"></script>
|
||||
</body>
|
||||
</html>{{end}}
|
||||
|
||||
{{define "flash"}}{{if .Flash}}<div class="flash ok">{{.Flash}}</div>{{end}}{{if .Error}}<div class="flash crit">{{.Error}}</div>{{end}}{{end}}
|
||||
|
||||
{{define "alertlist"}}{{if .}}
|
||||
<section class="card alerts-open">
|
||||
<h2>Open alerts</h2>
|
||||
{{range .}}<div class="alert {{.Level}}">
|
||||
<form method="post" action="/alerts/{{.ID}}/ack" class="x-form"><button type="submit" class="x" title="Acknowledge: hide until it changes or resolves">×</button></form>
|
||||
<div class="alert-title"><span class="badge {{.Level}}">{{.Level}}</span> {{.Title}}</div>
|
||||
<pre class="alert-detail">{{.Detail}}</pre>
|
||||
<div class="muted">since {{dt .OpenedAt}}</div>
|
||||
</div>{{end}}
|
||||
</section>{{end}}{{end}}
|
||||
Reference in New Issue
Block a user