원클릭으로
e2b-sandbox-debug
Spawn E2B sandbox for debugging and testing tools/commands in the container environment.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Spawn E2B sandbox for debugging and testing tools/commands in the container environment.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
| name | e2b-sandbox-debug |
| description | Spawn E2B sandbox for debugging and testing tools/commands in the container environment. |
Spawn a sandbox from the webmaster-sandbox-chrome template to test tools, commands, or file operations in the production container environment.
import { Sandbox } from '@e2b/code-interpreter'
const sandbox = await Sandbox.betaCreate('webmaster-sandbox-chrome', {
timeoutMs: 120_000,
})
bun auto-loads E2B_API_KEY from .env — no need to pass accessTokenconst res = await sandbox.commands.run('markitdown /tmp/test.html', {
cwd: '/home/user/sandbox', // optional
timeoutMs: 60_000, // optional
})
// res.exitCode, res.stdout, res.stderr
Note: commands.run() throws CommandExitError on non-zero exit codes. Catch it:
try {
const res = await sandbox.commands.run(cmd, { timeoutMs: 60_000 })
return { stdout: res.stdout, stderr: res.stderr, exitCode: res.exitCode }
} catch (e: unknown) {
if (e && typeof e === 'object' && 'exitCode' in e) {
const err = e as { exitCode: number; stdout: string; stderr: string }
return { stdout: err.stdout, stderr: err.stderr, exitCode: err.exitCode }
}
throw e
}
// Write file to sandbox
await sandbox.files.write('/tmp/test.html', '<h1>Hello</h1>')
// Read file from sandbox
const content = await sandbox.files.read('/tmp/test.txt', { format: 'text' })
const bytes = await sandbox.files.read('/tmp/img.png', { format: 'bytes' })
await sandbox.kill()
After changing containers/templates/chrome/template.ts:
bun run containers/templates/chrome/build.ts
Build takes ~3 minutes. Template alias is webmaster-sandbox-chrome.
containers/templates/chrome/template.ts — base image oven/bun:slim with:
Write a temporary .ts file and run with bun run <file>.ts. Delete after testing.
import { Sandbox } from '@e2b/code-interpreter'
async function main() {
const sandbox = await Sandbox.betaCreate('webmaster-sandbox-chrome', {
timeoutMs: 120_000,
})
try {
// ... run commands, write/read files, verify behavior
} finally {
await sandbox.kill()
}
}
main().catch(e => {
console.error(e)
process.exit(1)
})