satellite/console/consoleweb: suppress index.html loading errors
This change reverses behavior added by 45d5a93
that made the server
return a 500 status code when the index.html file for the satellite
frontend couldn't be loaded. The presence of this file was previously
intentionally optional.
Change-Id: I875a171a37b735c3523eb5b13d83f084f1781053
This commit is contained in:
parent
45d5a93085
commit
2193392e6b
@ -442,7 +442,7 @@ func (server *Server) appHandler(w http.ResponseWriter, r *http.Request) {
|
||||
} else {
|
||||
server.log.Error("error loading index.html", zap.String("path", path), zap.Error(err))
|
||||
}
|
||||
server.serveError(w, http.StatusInternalServerError)
|
||||
// Loading index is optional.
|
||||
return
|
||||
}
|
||||
|
||||
@ -454,8 +454,7 @@ func (server *Server) appHandler(w http.ResponseWriter, r *http.Request) {
|
||||
|
||||
info, err := file.Stat()
|
||||
if err != nil {
|
||||
server.log.Error("failed to retrieve file info", zap.Error(err))
|
||||
server.serveError(w, http.StatusInternalServerError)
|
||||
server.log.Error("failed to retrieve index.html file info", zap.Error(err))
|
||||
return
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user