(input: { source: string; id: string })
| 99 | } |
| 100 | |
| 101 | async startRuntime(input: { source: string; id: string }) { |
| 102 | await this.#workspace.fs.mkdir("/workspace", { recursive: true }); |
| 103 | const handle = await this.#workspace.runtime.exec(input.source, { |
| 104 | backend: "worker-javascript", |
| 105 | id: input.id, |
| 106 | }); |
| 107 | void handle.result().catch(() => undefined); |
| 108 | return handle.id; |
| 109 | } |
| 110 | |
| 111 | async getRuntime(id: string, resume?: "tail") { |
| 112 | try { |