feat: initialisation complète du CORE ProxmoxPanel
Backend Go 1.23+ : - API REST + WebSocket (chi, gorilla/websocket) - Authentification PAM via SSH + JWT RS256 - Chiffrement AES-256-GCM pour secrets SQLite - Pool SSH, client Proxmox REST, hub WebSocket pub/sub - Système de modules compilés à initialisation conditionnelle - Audit log, migrations SQLite versionnées Frontend Vue 3 + Vite + TypeScript : - Thème Neumorphism sombre/clair (CSS custom properties) - Wizard d'installation, Dashboard drag-drop, Terminal xterm.js - Toutes les vues CORE + stubs modules optionnels - i18n EN/FR (vue-i18n v11) Infrastructure : - Docker multi-stage (Go → alpine, Node → nginx) - docker-compose.yml, .gitattributes, LICENSE MIT, README Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
commit
5dbcb1df07
66 changed files with 10370 additions and 0 deletions
16
backend/internal/api/helpers.go
Normal file
16
backend/internal/api/helpers.go
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
// Fonctions utilitaires partagées entre les handlers API.
|
||||
package api
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// decodeJSON décode le corps JSON d'une requête dans dest.
|
||||
// Retourne une erreur si le corps est invalide ou manquant.
|
||||
func decodeJSON(r *http.Request, dest any) error {
|
||||
if r.Body == nil {
|
||||
return json.NewDecoder(r.Body).Decode(dest)
|
||||
}
|
||||
return json.NewDecoder(r.Body).Decode(dest)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue