openpod

An opencode plugin that spins up a dedicated virtual machine for each session to isolate agent work.
git clone https://unitehenry.com/git/openpod.git
Log | Files | Refs | README

commit 32bd6072c69f0fdf27caf55cc02b526fabba852a
parent 2a83594b48565da3bf975555cf84fc0129d822cc
Author: Henry Unite <unitehenry@gmail.com>
Date:   Sun, 25 Oct 2026 00:26:43 +0000

refactor(prompt): use sessionId directly instead of limaName alias

- Remove limaName variable (was just an alias for sessionId)
- Update limaInstanceExists, createLimaInstance, startLimaInstance to use sessionId directly
- Consistent with prior podDir -> target refactor

Diffstat:
Mprompt/handle.ts | 20+++++++++-----------
1 file changed, 9 insertions(+), 11 deletions(-)

diff --git a/prompt/handle.ts b/prompt/handle.ts @@ -59,13 +59,13 @@ export function handle(params: HandleParams): void { } } - function createLimaInstance(limaName: string, target: string): void { - logger.log(`creating lima instance ${limaName} (mount-only ${target}:w)`); + function createLimaInstance(sessionId: string, target: string): void { + logger.log(`creating lima instance ${sessionId} (mount-only ${target}:w)`); const createResult = spawnSync( "limactl", [ "create", - `--name=${limaName}`, + `--name=${sessionId}`, `--mount-only=${target}:w`, "template:default", "--yes", @@ -79,9 +79,9 @@ export function handle(params: HandleParams): void { } } - function startLimaInstance(limaName: string): void { - logger.log(`starting lima instance ${limaName}`); - const startResult = spawnSync("limactl", ["start", limaName, "--yes"], { + function startLimaInstance(sessionId: string): void { + logger.log(`starting lima instance ${sessionId}`); + const startResult = spawnSync("limactl", ["start", sessionId, "--yes"], { stdio: "ignore", }); if (startResult.status !== 0) { @@ -120,8 +120,6 @@ export function handle(params: HandleParams): void { `needs move for project dir ${dir}? ${needsMove} (target=${target})`, ); - const limaName = sessionId; - if (needsMove) { if (fs.existsSync(target)) { logger.log(`${target} already exists`); @@ -148,12 +146,12 @@ export function handle(params: HandleParams): void { } // 5. Create lima instance if necessary - if (!limaInstanceExists(limaName)) { - createLimaInstance(limaName, target); + if (!limaInstanceExists(sessionId)) { + createLimaInstance(sessionId, target); } // 6. Start lima instance - startLimaInstance(limaName); + startLimaInstance(sessionId); } export type { HandleParams };