The trailSailServer CLI
Everything the Server panel does is also a command on the server:
trailSailServer status [--json]
trailSailServer start|stop|restart splash|router|searxng|control
trailSailServer enable|disable splash|router|searxng
trailSailServer switch splash <repo> [--language-only] [--disable-ane]
trailSailServer switch router <model>
trailSailServer install splash <repo> · install router <repo:QUANT>
trailSailServer remove splash|router <model>
trailSailServer logs <engine> [--tail N]
trailSailServer pair --new · paired · unpair <name>
trailSailServer keys [--show] · rotate [engine] · update
trailSailServer memory · memory set 24GB|20480MB|auto
All subcommands accept --json. Add ~/.local/bin to your PATH, or use the full path.
Memory for models
trailSailServer memory shows how much of the Mac's memory models may use, the recommended amount, the range it can be set to, and a warning when it is too low for the configured model or too high for the Mac.
trailSailServer memory set 24GB # or 20480MB
trailSailServer memory set auto # back to the recommended amount
An amount outside the range is refused: the lowest is 4 GB and the highest is the Mac's memory less 2 GB. auto follows the recommendation for the Mac's memory. The command needs the helper the installer puts in place; on a server that has only been updated from the app it says to run the installer once on that Mac. If a model is loaded and the amount went down, it tells you to restart that engine; it does not restart anything itself.
The control API
For anyone building on it. GET /version and POST /pair {code, client} need no token; everything else needs Authorization: Bearer <token>:
GET /status,/keys,/paired,/engines/<e>/logs?tail=NPOST /engines/<e>/start|stop|restart|switch|install|remove,/rotate,/update,/pairing-codePOST /memory-limitwith{"mb": 20480}or{"automatic": true}: answers with thememoryobject of/statusplusrestartAdvised;400for an amount out of range,409withneedsInstallerwhen the helper is not installedDELETE /paired/<name>
Long actions stream Server-Sent Events, one JSON object per line: {"line": …} while working, then {"result": …} or {"error": …}. The daemon binds to localhost only; Tailscale terminates TLS. No shell is exposed.
Found a problem, or is something here unclear? Report it.