mirror of
https://github.com/tobychui/zoraxy.git
synced 2025-08-06 05:08:28 +02:00
18 lines
737 B
Markdown
18 lines
737 B
Markdown
# Configure
|
|
|
|
Configure or Configure Spec is the `exec` call where Zoraxy start the plugin. The configure spec JSON structure is defined in `zoraxy_plugin` library.
|
|
|
|
As the time of writing, the `ConfigureSpec` only contains information on some basic info.
|
|
|
|
```go
|
|
type ConfigureSpec struct {
|
|
Port int `json:"port"` //Port to listen
|
|
RuntimeConst RuntimeConstantValue `json:"runtime_const"` //Runtime constant values
|
|
//To be expanded
|
|
}
|
|
|
|
```
|
|
|
|
The `ConfigureSpec` struct will be parsed to JSON and pass to your plugin via the `-configure=(json payload here)`.
|
|
|
|
In your plugin, you can use the `zoraxy_plugin` library to parse it or parse it manually (if you are developing a plugin with other languages). |