Use Sandbox mode for secure execution
mainGrok can run shell commands inside a Shuru microVM sandbox to isolate the agent from your host filesystem and network.
Requirements: macOS 14+ on Apple Silicon.
Usage:
- CLI: Use the
--sandboxflag. - TUI: Use the
/sandboxcommand.
Sandbox Configuration Options:
- Network: Off by default. Use
--allow-netto enable or--allow-hostto restrict. - Port forwards: Use
--port 8080:80. - Resource limits: Configure CPUs, memory, and disk size via settings or the
/sandboxTUI panel. - Checkpoints: Start from a saved environment snapshot.
- Secrets: Inject API keys into the VM without exposing them to the guest.
Settings are stored in ~/.grok/workspace-trust.json for workspace-specific persistence, ~/.grok/user-settings.json for user-wide settings, and .grok/settings.json for project-specific settings.