Configuration
Kyushu works out of the box. Each command uses defaults but supports its own optional config file to override them.
The build config typically lives on your local machine and in CI, while the run config lives where you serve your worker.
Controls how kyu build bundles and pre-initializes your worker.
| Field | Type | Default | Description |
|---|---|---|---|
input.src | string | src/index.ts | Path to your TypeScript or JavaScript entry point |
output.dir | string | worker | Output directory for the built worker |
output.file | string | __kyushu_worker.wasm | Output filename for the built worker |
[input]src = "src/server.ts"
[output]dir = "dist"Scripts
Section titled “Scripts”Run shell commands before or after kyu build. Useful for example when using static assets, to build your frontend app or website beforehand.
[scripts]prebuild = ["pnpm build"]postbuild = ["echo done"]| Field | Type | Default | Description |
|---|---|---|---|
scripts.prebuild | array | — | Commands to run before kyu build |
scripts.postbuild | array | — | Commands to run after kyu build |
Assets
Section titled “Assets”Controls static asset bundling during kyu build. See the Static Assets guide for setup instructions.
| Field | Type | Default | Description |
|---|---|---|---|
assets.dir | string | — | Directory of static assets to bundle into the worker |
assets.precompress | array | — | Compression formats to pre-generate: "brotli", "gzip" |
[assets]dir = "dist"precompress = ["brotli", "gzip"]Controls how kyu run loads and serves your worker.
| Field | Type | Default | Description |
|---|---|---|---|
run.wasm | string | worker/__kyushu_worker.wasm | Path to the built worker .wasm file |
run.port | number | 5987 | Port to listen on |
worker.mounts | array | — | Filesystem mounts to expose to the worker |
worker.mounts[].host | string | — | Path on the host filesystem |
worker.mounts[].guest | string | — | Path inside the worker sandbox |
worker.mounts[].writable | bool | false | Whether the mount is writable |
worker.env | array | — | Environment variables to expose to the worker |
worker.env[].key | string | — | Environment variable name |
worker.env[].value | string | — | Environment variable value |
worker.network.ip_name_lookup | bool | false | Allow IP name lookup (resolving hostnames to IP addresses, e.g. DNS) |
worker.network.tcp | bool | false | Allow outbound TCP connections |
worker.network.udp | bool | false | Allow outbound UDP connections |
[run]wasm = "build/__custom_kyushu_worker.wasm"port = 8080
[[worker.mounts]]host = "./public"guest = "/public"
[[worker.mounts]]host = "./data"guest = "/data"writable = true
[[worker.env]]key = "API_KEY"value = "secret"
[worker.network]ip_name_lookup = truetcp = trueControls how kyu dev serves your worker during development with live-reload.
[dev]port = 5987 # default| Field | Type | Default | Description |
|---|---|---|---|
dev.port | number | 5987 | Port to listen on |
dev.watch | bool | true | Watch for file changes and reload automatically |
A custom [input] or [worker] configuration can also be applied; the details are omitted for brevity but follow the same options documented above.