fix(backend): make data root config authoritative
This commit is contained in:
@@ -35,6 +35,7 @@ export function createPiModelLister(cfg: AppConfig, opts: Opts = {}): () => Prom
|
||||
if (cache && now() - cache.at < ttlMs) return cache.models;
|
||||
|
||||
const env: NodeJS.ProcessEnv = { ...process.env };
|
||||
delete env.THT_DATA_ROOT;
|
||||
if (cfg.dataRoot !== undefined) env.THT_DATA_ROOT = cfg.dataRoot;
|
||||
const child = spawnFn(cfg.piBin, ["--mode", "rpc"], { cwd: cfg.harnessDir, env });
|
||||
child.stderr.resume();
|
||||
|
||||
Reference in New Issue
Block a user