Skip to content

Commit

Permalink
cmd/server: print full error message on http startup (#514)
Browse files Browse the repository at this point in the history
Towards #513
  • Loading branch information
arekkas committed Jun 13, 2017
1 parent e6920d3 commit b5cb0c6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cmd/server/handler.go
Expand Up @@ -77,7 +77,7 @@ func RunHost(c *config.Config) func(cmd *cobra.Command, args []string) {
},
})

pkg.Must(graceful.Graceful(func() error {
err := graceful.Graceful(func() error {
var err error
logger.Infof("Setting up http server on %s", c.GetAddress())
if c.ForceHTTP {
Expand All @@ -91,7 +91,8 @@ func RunHost(c *config.Config) func(cmd *cobra.Command, args []string) {
}

return err
}, srv.Shutdown), "Could not gracefully run server")
}, srv.Shutdown)
logger.WithError(err).Fatal("Could not gracefully run server")
}
}

Expand Down

0 comments on commit b5cb0c6

Please sign in to comment.