@bakers-build/addon-runtime-bwrap 0.10.1-next.8 → 0.10.1-next.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/launch.mjs +8 -4
- package/package.json +4 -4
package/launch.mjs
CHANGED
|
@@ -3,11 +3,15 @@ import { readFileSync, rmSync, writeFileSync } from 'node:fs';
|
|
|
3
3
|
|
|
4
4
|
const planPath = process.argv[2];
|
|
5
5
|
const plan = JSON.parse(readFileSync(planPath, 'utf8'));
|
|
6
|
-
// The executor's shell can carry unrelated secrets; only declared run keys
|
|
6
|
+
// The executor's shell can carry unrelated secrets; only declared run keys and the
|
|
7
|
+
// pane's terminal and locale variables (no secrets, needed for colour and redraw) enter bwrap.
|
|
8
|
+
const TERMINAL =
|
|
9
|
+
/^(TERM|COLORTERM|TERM_PROGRAM|TERM_PROGRAM_VERSION|LANG|LANGUAGE|LC_[A-Z_]+|NO_COLOR|FORCE_COLOR)$/;
|
|
7
10
|
const env = Object.fromEntries(
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
+
Object.entries(process.env).filter(
|
|
12
|
+
([key, value]) =>
|
|
13
|
+
value !== undefined && (plan.envKeys.includes(key) || TERMINAL.test(key)),
|
|
14
|
+
),
|
|
11
15
|
);
|
|
12
16
|
writeFileSync(`${planPath}.pid`, String(process.pid), { mode: 0o600 });
|
|
13
17
|
const child = spawn(plan.bwrap, plan.argv, { env, stdio: 'inherit' });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bakers-build/addon-runtime-bwrap",
|
|
3
|
-
"version": "0.10.1-next.
|
|
3
|
+
"version": "0.10.1-next.9",
|
|
4
4
|
"description": "Isolate complete agent runs with an external Bubblewrap sandbox.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -23,11 +23,11 @@
|
|
|
23
23
|
"directory": "bakers-cli/addons/runtime-bwrap"
|
|
24
24
|
},
|
|
25
25
|
"peerDependencies": {
|
|
26
|
-
"@bakers-build/conductor": "^0.10.1-next.
|
|
27
|
-
"@bakers-build/core": "^0.10.1-next.
|
|
26
|
+
"@bakers-build/conductor": "^0.10.1-next.9",
|
|
27
|
+
"@bakers-build/core": "^0.10.1-next.9"
|
|
28
28
|
},
|
|
29
29
|
"bakersBuild": {
|
|
30
|
-
"commit": "
|
|
30
|
+
"commit": "8e53a3481528f0a2c43c4783f2e1adf9385e0625",
|
|
31
31
|
"channel": "next"
|
|
32
32
|
}
|
|
33
33
|
}
|