Getting Started¶
Install¶
Or build from source:
Create a config¶
Create config.json5:
{
services: {
web: {
listen: ":8080",
routes: [
{
match: { path: "/*" },
action: "proxy",
},
],
},
},
actions: {
proxy: {
type: "proxy",
upstream: "localhost:3000",
timeout: "10s",
},
},
}
Validate¶
Run¶
With debug logging:
Hot Reload¶
Edit config.json5 while the server is running — changes are picked up automatically.
Or send SIGHUP:
Invalid configs are rejected gracefully — the server keeps running with the last valid config.
Directory Mode¶
Instead of a single config file, you can use a directory of service fragments:
Each .json5 file becomes a service (name = filename without extension).
CLI Reference¶
prox <command> [flags]
Commands:
serve Start the proxy server
validate Validate configuration (CI/CD)
version Print version
help Show help
Flags:
-config string Config file or directory (default "config.json5")
-log-level string debug, info, warn, error (default "info")
-watch Auto-reload on file change (default true)