logs-tool (Application Logs)
Application logs — read local and remote (k8s pod) logs. Part of @blogic-cz/agent-tools.
How to Run
Run via bun logs-tool (requires @blogic-cz/agent-tools as a dev dependency).
Auth: no auth needed for local files; uses k8s-tool for remote access.
Commands
bun logs-tool list --env local # List available log files
bun logs-tool read --env local --file app.log # Read specific log
bun logs-tool read --env test --file app.log --tail 50
bun logs-tool read --env test --file app.log --grep "connection refused"
--grep uses the same case-insensitive literal substring match for local and remote logs; it is not a regular expression. File paths are confined to the configured local or remote log directory. Treat configured log directories as trusted: workloads must not replace checked files or ancestors with symlinks during a read.
Environment is any string (e.g. local, test). Set defaultEnvironment in agent-tools.json5 to skip --env on every call.
Tips
- Use
bun logs-tool commandsfor the full machine-readable command/flag tree;--helpfor one subcommand. - Output defaults to TOON (token-efficient) — leave it as-is to save tokens. Add
--format jsononly when you'll machine-parse the result. - Error responses include
hint,nextCommand, andretryablefields — always check them on failure.