rpk ai sandbox
Create, inspect and delete sandboxes, and run commands and move files in them.
The create, get, list and delete commands manage the sandbox itself. Use the other commands to run commands, work with files, check usage or wake an idle sandbox. Each command’s help lists the permissions it needs.
A sandbox is created from a template (sandbox-template) and never changes
afterwards, so there is no update. It rests on its own when idle, and any
command or file call, or wake, brings it back.
sbx is short for sandbox: rpk ai sbx ls dev /workspace.
Subcommands
| Command | Description |
|---|---|
Create sandboxes from one or more YAML manifests. For each manifest: create the sandbox if absent, leave a matching one alone, and fail if a field the manifest sets differs from the live sandbox. |
|
Attach to a process that is running in a sandbox, usually one that |
|
Copy a file or directory between the local machine and a sandbox, the way docker cp does. One of SRC and DST is SANDBOX:PATH, where SANDBOX is a sandbox id or sandboxes/{id}; the other is a local path. |
|
Create a Sandbox. |
|
Delete a Sandbox. |
|
Dry-run of apply for sandboxes. Prints, per manifest, whether apply would create, update (and which fields), or leave the resource unchanged. |
|
Run a command in a sandbox and print what it wrote after it exits. A single COMMAND argument is a shell script, run with bash (sh in an image without bash). |
|
Get a Sandbox. |
|
List Sandboxes. |
|
List the entries of a directory at an absolute sandbox path. Requires |
|
List the processes the sandbox runtime tracks: those started by shell, exec and the agent’s sandbox tools, not every OS process. For OS processes, run |
|
Read a file at an absolute sandbox path and write its raw bytes to stdout or a local file. Pass |
|
Open an interactive shell in a sandbox, or run a command in it. Without a command, the shell is bash, or sh in an image without bash. |
|
Show what a running sandbox uses: memory, CPU seconds, processes and the /workspace volume. Reading usage neither wakes the sandbox nor counts as activity, so a sandbox at rest fails with FAILED_PRECONDITION: wake it first. |
|
Wake a sandbox that is at rest, and return after it runs again. Its /workspace and /tmp are as they were. |
|
Write a file at an absolute sandbox path from a local file or stdin. The file is replaced as a whole, and missing parent directories are created. |
Global flags
| Value | Type | Description |
|---|---|---|
|
string |
Redpanda or |
|
stringArray |
Override |
|
bool |
Ignore |
|
string |
|
|
bool |
Enable verbose logging. |