Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

Change services flag to loggers

Tomas Valenta58881de1cbd4
diff --git a/apps/docs/src/app/cli/commands/page.mdx b/apps/docs/src/app/cli/commands/page.mdx
index f9b09b2fe..fff780a00 100644
--- a/apps/docs/src/app/cli/commands/page.mdx
+++ b/apps/docs/src/app/cli/commands/page.mdx
@@ -268,7 +268,7 @@ You can use `e2b sandbox list` to get a list of running sandboxes and their IDs
#### **Options**
<Options>
- <Option name="level" type="-l, --level">
+ <Option name="level" type="--level">
Filter logs by level — allowed values are `DEBUG`, `INFO`, `WARN`, `ERROR`.
The logs with the higher levels will be also shown.
@@ -282,9 +282,9 @@ You can use `e2b sandbox list` to get a list of running sandboxes and their IDs
Default value is `pretty`.
</Option>
- <Option name="services" type="--services">
- Specify services for printing logs — allowed values are `process`, `filesystem`, `terminal`, `network`.
- You can specify multiple services by separating them with a comma.
+ <Option name="loggers" type="--loggers">
+ Specify enabled loggers — allowed values are `process`, `filesystem`, `terminal`, `network`.
+ You can specify multiple loggers by separating them with a comma.
Default value is `process,filesystem`.
</Option>
diff --git a/packages/cli/src/commands/sandbox/logs.ts b/packages/cli/src/commands/sandbox/logs.ts
index d70020b5d..b6c4126ca 100644
--- a/packages/cli/src/commands/sandbox/logs.ts
+++ b/packages/cli/src/commands/sandbox/logs.ts
@@ -106,10 +106,10 @@ export const logsCommand = new commander.Command('logs')
.description('show logs for sandbox')
.argument('<sandboxID>', `show logs for sandbox specified by ${asBold('<sandboxID>')}`)
.alias('lg')
- .option('-l, --level <level>', `filter logs by level (${formatEnum(LogLevel)}). The logs with the higher levels will be also shown.`, LogLevel.INFO)
+ .option('--level <level>', `filter logs by level (${formatEnum(LogLevel)}). The logs with the higher levels will be also shown.`, LogLevel.INFO)
.option('-f, --follow', 'keep streaming logs until the sandbox is closed')
.option('--format <format>', `specify format for printing logs (${formatEnum(LogFormat)})`, LogFormat.PRETTY)
- .option('-s, --services [services]', `filter logs by service. The available services are ${formatEnum(LogService)}. Specify multiple services by separating them with a comma.`, (value) => {
+ .option('--loggers [loggers]', `filter logs by loggers. The available loggers are ${formatEnum(LogService)}. Specify multiple loggers by separating them with a comma.`, (value) => {
const services = value.split(',').map(s => s.trim()) as LogService[]
// Check if all services are valid
services.forEach(s => {