diff --git a/server/internal/api/console.go b/server/internal/api/console.go index a714156..a14be12 100644 --- a/server/internal/api/console.go +++ b/server/internal/api/console.go @@ -3,6 +3,7 @@ package api import ( "errors" "fmt" + "log" "net" "net/http" "os" @@ -147,6 +148,12 @@ func consoleTunnel(c *gin.Context) { c.JSON(http.StatusConflict, gin.H{"error": "agent_offline"}) return } + // Logged as well as answered. The client is deliberately told nothing + // specific, but this is the only place the real reason exists — a + // failed dispatch and a relay that was never announced are the same + // generic 500 to the browser, and guacamole then reports the missing + // upgrade as an upstream error, which points at the wrong hop entirely. + log.Printf("console: open relay for server %s: %v", srv.ServerID, err) c.JSON(http.StatusInternalServerError, gin.H{"error": "could not open relay"}) return }