Render contextual errors? This enables bun's error page
Symbol
ServeOptions
interface ServeOptions
- id?: null | string
Uniquely identify a server instance with an ID
When bun is started with the
--hot
flagThis string will be used to hot reload the server without interrupting pending requests or websockets. If not provided, a value will be generated. To disable hot reloading, set this value to
null
.When bun is not started with the
--hot
flagThis string will currently do nothing. But in the future it could be useful for logs or metrics.
- idleTimeout?: number
Sets the the number of seconds to wait before timing out a connection due to inactivity.
Default is
10
seconds. - reusePort?: boolean
Whether the
SO_REUSEPORT
flag should be set.This allows multiple processes to bind to the same port, which is useful for load balancing.
- unix?: undefined
If set, the HTTP server will listen on a unix socket instead of a port. (Cannot be used with hostname+port)