33800 Docs

← Retour

Proposition : Architecture Unifiée Dashboard + Mémoire Claude

Date : 21/01/2026 19:15 Status : EN ATTENTE VALIDATION

Vision Globale

                         SOURCE UNIQUE
                              │
              ┌───────────────┼───────────────┐
              │               │               │
              ▼               ▼               ▼
         config.json     APIs Live      Registres JSON
              │               │               │
              │               │               │
     ┌────────┴────────┐     │      ┌────────┴────────┐
     │                 │     │      │                 │
     ▼                 ▼     ▼      ▼                 ▼
 index/*.md         HTML   HTML  services-         memory/*.md
 (CLAUDE)          Static  Live  registry.json     (CLAUDE)
     │                 │     │         │               │
     │                 └──┬──┘         │               │
     │                    │            │               │
     │                    ▼            │               │
     │              DASHBOARD          │               │
     │        dashboard.nowhere84.com  │               │
     │                    │            │               │
     └────────────────────┼────────────┘               │
                          │                            │
                          ▼                            │
                   claude.nowhere84.com ◄──────────────┘
                   (intégré au dashboard)

Audit Dashboard - 23 Pages

Pages STATIQUES (OK tel quel) - 10 pages

Page Sujet Raison
doc.html Documentation Référence, change rarement
endpoints.html API endpoints Référence
models.html Guide modèles Ollama Référence
montages.html Montages NFS/SMB Stable
nginx.html Configuration Nginx Change rarement
o2switch.html Services O2switch Change rarement
secrets.html Credentials Référence
syncthing.html Syncthing config Stable
architecture.html Vue architecture Change rarement
shortlinks.html Liens raccourcis Manuel

Pages LIVE (déjà OK) - 3 pages

Page API utilisée Refresh
ai-orchestrator.html ai-orchestrator.33800/api/tools 30s JS
ai-jobs.html ai-orchestrator.33800/api/jobs 5s JS
needfinder-v2.html API fetch JS

Pages à PASSER EN LIVE - 6 pages

Page Sujet Pourquoi live ? API à créer
index.html Dashboard principal Status services temps réel /api/status
services.html Services déployés Changent souvent /api/services
alerts.html Alertes système Critiques /api/alerts
raidz.html Status ZFS Health critique /api/zfs
crons.html Timeline crons Dernière exécution /api/crons
linkedin.html LinkedIn connector Session status browser-connector/api

Pages HYBRID (à évaluer) - 4 pages

Page Status actuel Recommandation
schema.html Canvas dynamique OK
yolo.html Détection OK si utilisé
needfinder.html V1 obsolète Supprimer ?

Intégration claude.nowhere84.com

Actuellement

Proposition

Intégrer comme page du dashboard :

dashboard.nowhere84.com/
├── index.html
├── services.html
├── ...
└── claude.html          ← NOUVEAU (remplace claude.nowhere84.com)
    ├── propositions/
    ├── tasks/
    └── backlog/

Avantages :

Fichiers à Splitter (>500 lignes)

Fichier Lignes Split en
01-index.sh 1392 index-header.sh, index-services.sh, index-stats.sh
05-endpoints.sh 1221 endpoints-prod.sh, endpoints-dev.sh, endpoints-ai.sh
20-ai-jobs.sh 1086 ai-jobs-stats.sh, ai-jobs-grid.sh, ai-jobs-modal.sh
18-ai-tools.sh 1051 ai-tools-cards.sh, ai-tools-docs.sh
03-doc.sh 934 doc-general.sh, doc-api.sh
08-crons.sh 815 crons-timeline.sh, crons-list.sh

Règle : Max 500 lignes par fichier

Architecture API Unifiée

Nouvelle API : infra-status (à créer)

Container sur prod-portainer qui centralise les status :

infra-status.33800.nowhere84.com/api/
├── /status          # Status global (pour index.html)
├── /services        # Services déployés (services-registry.json)
├── /alerts          # Alertes actives
├── /zfs             # Status ZFS pools
├── /crons           # Dernières exécutions crons
└── /machines        # Status machines (ping)

Implémentation : Simple Node.js/Bun qui :

APIs existantes (déjà OK)

API URL Pages
ai-orchestrator ai-orchestrator.33800/api ai-jobs, ai-orchestrator
browser-connector browser.33800/api linkedin

Source Unique : config.json étendu

{
  "hosts": { ... },           // Machines
  "services": { ... },        // Services
  "urls": { ... },            // URLs actives (NOUVEAU)
  "credentials_index": { ... } // Liste credentials sans valeurs (NOUVEAU)
}

Génération automatique

# generate.sh génère :
# 1. Pages HTML du dashboard
# 2. Fichiers index/*.md pour Claude

generate_dashboard()    # HTML statiques
generate_live_pages()   # HTML avec JS fetch
generate_claude_index() # index/*.md

Structure Mémoire Claude (rappel)

~/.claude/
├── CLAUDE.md              # Core (~200 lignes) - TOUJOURS
├── index/                 # Niveau 2 - AUTO si sujet détecté
│   ├── services.md        # ← Généré depuis config.json
│   ├── machines.md        # ← Généré depuis config.json
│   ├── urls.md            # ← Généré depuis config.json
│   └── credentials-index.md
└── memory/                # Niveau 3 - À LA DEMANDE
    ├── o2switch.md
    ├── notifications.md
    └── ...

Plan d'Exécution

Phase 1 : Splitter les gros fichiers (1-2h)

  1. Split 01-index.sh en 3 fichiers
  2. Split 05-endpoints.sh en 3 fichiers
  3. Split les autres fichiers >500 lignes
  4. Tester generate.sh

Phase 2 : Créer infra-status API (2-3h)

  1. Créer projet infra-status sur GitLab
  2. Endpoints : /status, /services, /zfs, /alerts
  3. Déployer sur prod-portainer
  4. Configurer nginx

Phase 3 : Passer pages en live (2-3h)

  1. Modifier index.html → fetch /api/status
  2. Modifier services.html → fetch /api/services
  3. Modifier alerts.html → fetch /api/alerts
  4. Modifier raidz.html → fetch /api/zfs
  5. Modifier crons.html → fetch /api/crons

Phase 4 : Intégrer claude.nowhere84.com (1h)

  1. Créer generate.d/30-claude.sh
  2. Générer claude.html avec viewer MD
  3. Mettre à jour navigation
  4. Rediriger claude.nowhere84.com → dashboard/claude.html

Phase 5 : Générer index Claude (1h)

  1. Créer script generate-claude-index.sh
  2. Intégrer dans generate.sh
  3. Créer structure ~/.claude/index/
  4. Tester chargement proactif

Phase 6 : Réduire CLAUDE.md (1h)

  1. Backup CLAUDE.md actuel
  2. Créer nouveau CLAUDE.md core
  3. Migrer détails vers memory/
  4. Tester session

Résumé Final

Composant Avant Après
Dashboard pages 23 (majoritairement statiques) 23 (6 live, 10 statiques, intégrées)
claude.nowhere84.com Séparé Intégré au dashboard
CLAUDE.md 1355 lignes ~200 lignes core
Gros fichiers 6 fichiers >500 lignes Tous <500 lignes
Données live 3 pages 9 pages
Source unique Partielle config.json + APIs

Validation requise


En attente de ta validation.