chore: initialise la structure du projet SentinelMesh
- Workspace Cargo avec backend, agent-scan-network, agent-metric - Skeleton Rust pour les trois crates (Axum, Tokio, SQLx) - Documentation : README, FEATURES, ROADMAP, ARCHITECTURE, API, INSTALL - Exemples de widgets Glance (custom-api) - Script d'installation agents (squelette Phase 5) - Docker Compose + Dockerfile backend - .gitignore et CLAUDE.md Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
# Exemple de widget Glance — Métriques système SentinelMesh
|
||||
# À intégrer dans votre glance.yml
|
||||
- type: custom-api
|
||||
title: Métriques systèmes
|
||||
cache: 1s
|
||||
url: http://sentinelmesh:8080/api/v1/widgets/metrics
|
||||
template: |
|
||||
{{ range .agents }}
|
||||
<div class="widget-type-sentinelmesh-metrics">
|
||||
<h3>{{ .hostname }}</h3>
|
||||
<div>CPU: {{ .cpu_percent }}%</div>
|
||||
<div>RAM: {{ .ram_percent }}%</div>
|
||||
<div>Temp: {{ .temperature_c }}°C</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
@@ -0,0 +1,19 @@
|
||||
# Exemple de widget Glance — Découverte réseau SentinelMesh
|
||||
# À intégrer dans votre glance.yml
|
||||
- type: custom-api
|
||||
title: Réseau local
|
||||
cache: 30s
|
||||
url: http://sentinelmesh:8080/api/v1/widgets/network
|
||||
template: |
|
||||
{{ range .sections }}
|
||||
<div class="widget-type-sentinelmesh-network">
|
||||
<h3>{{ .name }} — {{ .cidr }}</h3>
|
||||
{{ range .items }}
|
||||
<div class="device {{ .state }}">
|
||||
<span class="hostname">{{ .hostname }}</span>
|
||||
<span class="ip">{{ .ip }}</span>
|
||||
<span class="state">{{ .state }}</span>
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
Reference in New Issue
Block a user