fix: SSHAuthenticator vide après installation + logs debug
Bug principal : l'SSHAuthenticator est créé au démarrage avec host="" (DB vide avant installation). Après configure, il gardait host vide. Le login lisait maintenant le ssh_host depuis la DB à chaque requête. Logs ajoutés : - ssh_auth.go : dial SSH, succès, échec avec détail d'erreur - auth.go : host SSH utilisé, résultat auth à chaque login - updates.go : credentials SSH, démarrage/fin de job - terminal.go : ouverture/échec session SSH Frontend : - auth.store.ts : gère les réponses non-JSON sur erreur HTTP Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
15965082ce
commit
07af66ad81
5 changed files with 46 additions and 7 deletions
|
|
@ -53,8 +53,12 @@ export const useAuthStore = defineStore('auth', () => {
|
|||
})
|
||||
|
||||
if (!res.ok) {
|
||||
const err = await res.json()
|
||||
throw new Error(err.error || 'Erreur d\'authentification')
|
||||
const contentType = res.headers.get('content-type') || ''
|
||||
if (contentType.includes('application/json')) {
|
||||
const err = await res.json()
|
||||
throw new Error(err.error || 'Erreur d\'authentification')
|
||||
}
|
||||
throw new Error(`Erreur ${res.status} — réponse inattendue du serveur`)
|
||||
}
|
||||
|
||||
const data = await res.json()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue