oc exec <id> [flags] -- <command...>
By default, creates an exec session and prints the session ID with attach instructions. Use --wait to run synchronously.
HTTP API →
Wait for completion, stream output, mirror exit code
Working directory
Timeout in seconds (0 = none)
Environment variable
KEY=VALUE (repeatable)oc exec list <id>
List active exec sessions for a sandbox. HTTP API →
Output: session ID, status (running or exited (code)), command, client count.
oc exec attach <id> <session-id>
oc exec kill <id> <session-id>
Kill an exec session. HTTP API →
Signal number (default: SIGKILL)