Config struct is the root configuration object for a workerd instance. It defines services, sockets, and runtime behavior.
Structure
List of named services defined by this server. Services are not reachable until configured through a Socket or binding.If no service named “internet” is defined, one is created implicitly representing access to public internet servers.
List of sockets on which the server will listen and expose services.
Command-line flags to pass to V8, like
--expose-gc. Use with caution as flags can have unpredictable effects and may change between V8 versions.Extensions provide capabilities to all workers. Extensions are typically prepared separately and late-linked using this config field.
List of autogates to enable. Autogates are used to conditionally enable features and changes in workerd.
Console and stdio logging configuration options.
Logging options
If true, logs are emitted as JSON for structured logging. When false, logs use the traditional human-readable format.
Custom prefix for process.stdout. Defaults to
stdout: .Custom prefix for process.stderr. Defaults to
stderr: .