Skip to content

Commit

Permalink
backend: Print error if server fails to start
Browse files Browse the repository at this point in the history
Signed-off-by: Oleksandr Dubenko <oldubenko@microsoft.com>
  • Loading branch information
sniok committed Aug 8, 2024
1 parent ecec4f9 commit 68026d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/cmd/headlamp.go
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,7 @@ func StartHeadlampServer(config *HeadlampConfig) {
// Start server
err := http.ListenAndServe(fmt.Sprintf(":%d", config.port), handler) //nolint:gosec
if err != nil {
logger.Log(logger.LevelError, nil, nil, "Failed to start server")
logger.Log(logger.LevelError, nil, err, "Failed to start server")
os.Exit(1)
}
}
Expand Down

0 comments on commit 68026d5

Please sign in to comment.