feat: add polling system to dynamic reloading

This commit is contained in:
Yuan Teoh
2026-02-12 15:31:00 -08:00
parent f032389a07
commit c1f19d3d15
4 changed files with 73 additions and 3 deletions

View File

@@ -28,6 +28,7 @@ description: >
| | `--allowed-origins` | Specifies a list of origins permitted to access this server for CORs access. | `*` |
| | `--allowed-hosts` | Specifies a list of hosts permitted to access this server to prevent DNS rebinding attacks. | `*` |
| | `--user-agent-metadata` | Appends additional metadata to the User-Agent. | |
| | `--poll-interval` | Specifies the polling frequency (seconds) for configuration file updates. | `0` |
| `-v` | `--version` | version for toolbox | |
## Sub Commands
@@ -136,6 +137,16 @@ used at a time.
Toolbox enables dynamic reloading by default. To disable, use the
`--disable-reload` flag.
Use the `--polling-interval` flag to manually detect configuration file updates.
When the polling interval is `0`, the polling system is disabled.
{{< notice tip >}}
FOr polling to be effective when running Kubernetes, PersistentVolume or
StorageClass must be set to refresh attributes rapidly by setting `actimeo=1`.
Actimeo setting determines the duration for which a client trusts its local
cache for file attributes.
{{< /notice >}}
### Toolbox UI
To launch Toolbox's interactive UI, use the `--ui` flag. This allows you to test