@outerlayer/cli 0.5.0 → 0.6.0
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/CHANGELOG.md +17 -0
- package/README.md +9 -0
- package/dist/{agent-setup-IFH3FB5X.js → agent-setup-USZ2SAXC.js} +2 -2
- package/dist/build-info.json +1 -1
- package/dist/{check-AXCXDYO2.js → check-CCVPBN7A.js} +26 -14
- package/dist/{chunk-5Y3QQRUH.js → chunk-3DD6AOWC.js} +37 -0
- package/dist/{chunk-WOBNRVQT.js → chunk-3DEVYTNQ.js} +1 -1
- package/dist/{chunk-L24G4PLP.js → chunk-43J3M6KB.js} +486 -21
- package/dist/{chunk-FC7TMRNA.js → chunk-4NLKY4WR.js} +2 -2
- package/dist/{lima-XN65D7GN.js → chunk-77MM5RYD.js} +0 -1
- package/dist/{chunk-D2KWEAN6.js → chunk-7DBI6SNT.js} +1 -1
- package/dist/{chunk-QDQEUVUF.js → chunk-AIW6GLET.js} +1 -1
- package/dist/{chunk-EX6M5JPR.js → chunk-ANK2B36Y.js} +131 -15
- package/dist/{chunk-RMAZ2NWA.js → chunk-BNMCXPG7.js} +14 -2
- package/dist/{chunk-UFFXNXLQ.js → chunk-FA2BOX4O.js} +31 -29
- package/dist/chunk-FBTE2A2X.js +38 -0
- package/dist/{chunk-DVDEBNQJ.js → chunk-GQD22KKN.js} +17 -6
- package/dist/{chunk-BCJNHMZT.js → chunk-HHJDN6AU.js} +18 -3
- package/dist/{chunk-JLDZTG3A.js → chunk-IASWYRVG.js} +1 -1
- package/dist/{install-cmd-7WXOIFDO.js → chunk-JWOQNNN2.js} +0 -1
- package/dist/{chunk-ZLB7GCTY.js → chunk-MIGEDH5P.js} +19 -11
- package/dist/{chunk-OHFDWLJP.js → chunk-MXB5VB4Y.js} +18 -6
- package/dist/chunk-NQXFAGHU.js +211 -0
- package/dist/chunk-OUUINEYB.js +27 -0
- package/dist/{chunk-OR6AEEDO.js → chunk-PMAMOSTP.js} +3 -3
- package/dist/{chunk-RJ467PDQ.js → chunk-RBOMWNOG.js} +1 -1
- package/dist/{chunk-4NMBDRBS.js → chunk-RZSF5B46.js} +289 -130
- package/dist/chunk-T6OIJQRT.js +31 -0
- package/dist/chunk-UGP76IZ5.js +34 -0
- package/dist/{chunk-EGABNHZG.js → chunk-UMFWVGJO.js} +148 -18
- package/dist/{chunk-RWOTHXYE.js → chunk-VMJ3MMBX.js} +206 -71
- package/dist/chunk-YYYRBYWG.js +32 -0
- package/dist/chunk-ZILGTTY6.js +75 -0
- package/dist/{cli-NNWPFP5S.js → cli-7WCNPBYC.js} +147 -69
- package/dist/command-ARFK3OYF.js +162 -0
- package/dist/{config-XVJYZ4IQ.js → config-HL2AIR3K.js} +1 -1
- package/dist/{connect-cmd-OJBFHZWP.js → connect-cmd-PCESZLTR.js} +4 -4
- package/dist/{context-adopt-UMA4O5NY.js → context-adopt-G5JAELE7.js} +2 -2
- package/dist/{context-materialize-G2FUFC72.js → context-materialize-3HLPZAF6.js} +2 -2
- package/dist/{dist-WDV7U7UJ.js → dist-RDLP4GGJ.js} +1 -1
- package/dist/{doctor-J3GIMR7K.js → doctor-VOMYOHQU.js} +47 -13
- package/dist/{emit-artifact-cmd-FDWYKURA.js → emit-artifact-cmd-TBF46VXZ.js} +6 -7
- package/dist/{emit-criteria-cmd-OCXHLK34.js → emit-criteria-cmd-3427XKFW.js} +3 -3
- package/dist/{emit-finding-cmd-POW7PKIA.js → emit-finding-cmd-GSI75K36.js} +3 -3
- package/dist/{emit-result-cmd-ID35SH53.js → emit-result-cmd-3PRQKB55.js} +6 -7
- package/dist/{hook-fast-EYENPK6F.js → hook-fast-NJBBZQ5Q.js} +1 -1
- package/dist/index.js +3 -2
- package/dist/{init-CZX7ZDWF.js → init-OHYFIKZD.js} +27 -56
- package/dist/{init-3ZQLFPNC.js → init-WVR4BZQ4.js} +8 -8
- package/dist/{init-cmd-W5NOLQPX.js → init-cmd-HMFNIFPI.js} +7 -7
- package/dist/inspect-XAUSB7L3.js +63 -0
- package/dist/install-DSUZE2TJ.js +13 -0
- package/dist/install-cmd-453C7IZT.js +8 -0
- package/dist/lima-7NPCNGWT.js +6 -0
- package/dist/{loop-VGM772I7.js → loop-UAJB34KA.js} +26 -11
- package/dist/{machine-5WEJA36F.js → machine-2JOWGRSZ.js} +7 -7
- package/dist/record-C43U4PKS.js +7 -0
- package/dist/session-sender-ED26V45B.js +28 -0
- package/dist/{status-KBDVUYQ3.js → status-6WNXX2O7.js} +42 -10
- package/dist/{sync-cmd-SWQ5KLPL.js → sync-cmd-YONVGUYS.js} +6 -7
- package/dist/{watch-3YW6Z3DQ.js → watch-HHKAF26L.js} +6 -7
- package/dist/{work-claim-cmd-BQPPURBW.js → work-claim-cmd-LXBZTMJA.js} +6 -6
- package/dist/{work-cmd-NUR4CAG6.js → work-cmd-OVNF44FY.js} +3 -3
- package/dist/{work-comment-cmd-6TTTYGHM.js → work-comment-cmd-6DGQNTAH.js} +3 -3
- package/dist/{work-launch-YI4CJDAP.js → work-launch-R5HTAP6X.js} +1 -1
- package/dist/{work-open-pr-cmd-KZ7QQFLD.js → work-open-pr-cmd-FCZHFHZS.js} +4 -4
- package/dist/{work-pr-cmd-QNUBE6IQ.js → work-pr-cmd-QJJVHZDC.js} +2 -2
- package/package.json +2 -1
- package/dist/chunk-ZOC7JSYC.js +0 -83
- package/dist/{chunk-XDDW4FRS.js → chunk-OIRNH6UO.js} +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# @outerlayer/cli
|
|
2
2
|
|
|
3
|
+
## 0.6.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- cb41102: A runner build's agent session now appears on its work item, with its running cost, while the build runs. The runner starts a hidden `session-sender` command beside each build's command, in a microVM, a container, a host `exec` hook or on the host. The end-of-attempt sync stays the complete upload. The capture daemon gains a watch-only mode that reports changed transcripts without copying them.
|
|
8
|
+
- 21b7405: `outerlayer runner init` now sets the runner up to keep running on Linux, macOS and Windows (WSL2), with the same commands on each: `runner install --service` (with `--print`, `--user` and `--replace`) writes, enables and starts one systemd unit, and `runner uninstall --service` removes it. Each microVM build runs in a cgroup of its own with a memory limit of `build.memory` plus 256 MiB, and a build the kernel kills for want of memory ends `failed` with a reason that says so, without stopping the runner or the other builds. Setup refuses builds that cannot fit in memory together. The runner claims nothing, and says why in its heartbeat as `blocked`, when it cannot open `/dev/kvm`, has no Claude credential, still has the placeholder command, or has builds that do not fit in memory. `outerlayer doctor` now reports the running service's groups and credential instead of your shell's. The runner now reports protocol 14 to its gateway.
|
|
9
|
+
|
|
10
|
+
### Patch Changes
|
|
11
|
+
|
|
12
|
+
- 573abaa: A session link that worked no longer leaves a Node warning in `~/.outerlayer/spool/hook-errors.log`. Only links that fail are logged, with one line naming the item.
|
|
13
|
+
|
|
14
|
+
## 0.5.1
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- 1cc839a: The runner now cleans up after itself and stops taking builds when its disk is nearly full. A new `runner.housekeeping` block in the runner config sets how many days a finished build's job directory is kept (`jobsKeepDays`), the most the Docker build cache may hold (`buildCacheMax`, or `"off"`), and the free space the runner needs to claim work (`minFreeDisk`). The runner also removes build containers and volumes that a failed cleanup left behind. `outerlayer runner status` shows what housekeeping did and whether the runner is holding off for disk, and `outerlayer doctor` checks free disk space. The runner now reports protocol 13 to its gateway.
|
|
19
|
+
|
|
3
20
|
## 0.5.0
|
|
4
21
|
|
|
5
22
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -56,6 +56,15 @@ send, so turning it off takes effect without restarting the daemon.
|
|
|
56
56
|
authoritative upload — the daemon exists so a session's page can follow
|
|
57
57
|
along before that sync ever runs.
|
|
58
58
|
|
|
59
|
+
**`outerlayer session-sender` is started only by a runner, inside each build,
|
|
60
|
+
and streams that build's sessions to its work item while the build runs.** It
|
|
61
|
+
sends under the build's own item key to the build's own gateway, both taken
|
|
62
|
+
from the job's environment and never from your config file, and only sessions
|
|
63
|
+
the build itself launched. It sends no session that belongs to anyone else on
|
|
64
|
+
the machine, and your own `outerlayer daemon` skips sessions launched inside a
|
|
65
|
+
runner build. The runner stops it before the build's final `outerlayer sync`,
|
|
66
|
+
which remains the complete upload.
|
|
67
|
+
|
|
59
68
|
These commands also talk to your workspace. None of them sends session
|
|
60
69
|
content:
|
|
61
70
|
|
|
@@ -4,11 +4,11 @@ import { installStarterPack } from './chunk-ZMYPLFG3.js';
|
|
|
4
4
|
import { runEmit } from './chunk-H5NCNVDA.js';
|
|
5
5
|
import { addStdioMcpEntryIfAbsent } from './chunk-MQ3IPHIZ.js';
|
|
6
6
|
import { C } from './chunk-YRYMNBGQ.js';
|
|
7
|
-
import { resolveGitCommonDir, defaultGitRunner } from './chunk-
|
|
7
|
+
import { resolveGitCommonDir, defaultGitRunner } from './chunk-OIRNH6UO.js';
|
|
8
|
+
import './chunk-ZJSNLVCE.js';
|
|
8
9
|
import { pinExists, readContextManifest } from './chunk-WIOZAJ2W.js';
|
|
9
10
|
import { loadTemplateFiles, loadMaintainedFiles, skillDir } from './chunk-WO2BXCTQ.js';
|
|
10
11
|
import { generatedHeaderSource } from './chunk-EMY4I27X.js';
|
|
11
|
-
import './chunk-ZJSNLVCE.js';
|
|
12
12
|
import './chunk-BCLJSQCV.js';
|
|
13
13
|
import './chunk-BOLTI6LR.js';
|
|
14
14
|
import './chunk-EABW6AJQ.js';
|
package/dist/build-info.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"id":"2026-10-
|
|
1
|
+
{"id":"2026-10-04T12:35:01.048Z+a19ef31","root":"/home/runner/_work/outerlayer/outerlayer","pkg":"outerlayer"}
|
|
@@ -1,17 +1,23 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { probeCredentials } from './chunk-
|
|
4
|
-
import './chunk-RWOTHXYE.js';
|
|
5
|
-
import './chunk-QDQEUVUF.js';
|
|
3
|
+
import { probeCredentials } from './chunk-43J3M6KB.js';
|
|
6
4
|
import './chunk-ABIWDUMS.js';
|
|
7
5
|
import './chunk-YYYXRJUW.js';
|
|
6
|
+
import './chunk-VMJ3MMBX.js';
|
|
7
|
+
import './chunk-T6OIJQRT.js';
|
|
8
|
+
import './chunk-AIW6GLET.js';
|
|
9
|
+
import './chunk-UGP76IZ5.js';
|
|
10
|
+
import './chunk-ZILGTTY6.js';
|
|
8
11
|
import './chunk-CBPPJSAR.js';
|
|
9
|
-
import
|
|
10
|
-
import './chunk-
|
|
12
|
+
import './chunk-UMFWVGJO.js';
|
|
13
|
+
import './chunk-HHJDN6AU.js';
|
|
14
|
+
import { placeholderQueues, placeholderProblem, needsClaudeCredential, claudeCredentialCheck, claimPermissionProblem } from './chunk-MXB5VB4Y.js';
|
|
15
|
+
import './chunk-YYYRBYWG.js';
|
|
11
16
|
import './chunk-TBT347UY.js';
|
|
12
|
-
import './chunk-
|
|
13
|
-
import './chunk-
|
|
14
|
-
import './chunk-
|
|
17
|
+
import './chunk-OUUINEYB.js';
|
|
18
|
+
import './chunk-4NLKY4WR.js';
|
|
19
|
+
import './chunk-RBOMWNOG.js';
|
|
20
|
+
import './chunk-RZSF5B46.js';
|
|
15
21
|
import './chunk-Z62HNKEJ.js';
|
|
16
22
|
import './chunk-N5FOE5PS.js';
|
|
17
23
|
import './chunk-OGFGZQA3.js';
|
|
@@ -19,25 +25,31 @@ import './chunk-774HEQL6.js';
|
|
|
19
25
|
import './chunk-QOZKPLVJ.js';
|
|
20
26
|
import './chunk-W4SQCOZU.js';
|
|
21
27
|
import './chunk-B2G7JHHB.js';
|
|
22
|
-
import './chunk-
|
|
28
|
+
import './chunk-F7CU5ABH.js';
|
|
29
|
+
import './chunk-BKO6JEZI.js';
|
|
30
|
+
import './chunk-BNMCXPG7.js';
|
|
23
31
|
import './chunk-BFESLKPP.js';
|
|
24
|
-
import './chunk-
|
|
25
|
-
import './chunk-
|
|
26
|
-
import
|
|
32
|
+
import './chunk-3DEVYTNQ.js';
|
|
33
|
+
import './chunk-ANK2B36Y.js';
|
|
34
|
+
import './chunk-YRYMNBGQ.js';
|
|
35
|
+
import { loadRunnerConfig, RunnerConfigError, checkHooks } from './chunk-3DD6AOWC.js';
|
|
27
36
|
import './chunk-F6GFZXZ3.js';
|
|
28
37
|
import './chunk-AUFG23AA.js';
|
|
38
|
+
import './chunk-GQD22KKN.js';
|
|
29
39
|
import './chunk-WZBHBH3J.js';
|
|
30
|
-
import './chunk-
|
|
40
|
+
import './chunk-5QRP3MVS.js';
|
|
41
|
+
import './chunk-OIRNH6UO.js';
|
|
42
|
+
import './chunk-ZJSNLVCE.js';
|
|
31
43
|
import './chunk-WIOZAJ2W.js';
|
|
32
44
|
import './chunk-WO2BXCTQ.js';
|
|
33
45
|
import './chunk-EMY4I27X.js';
|
|
34
|
-
import './chunk-ZJSNLVCE.js';
|
|
35
46
|
import './chunk-BCLJSQCV.js';
|
|
36
47
|
import './chunk-BOLTI6LR.js';
|
|
37
48
|
import './chunk-EABW6AJQ.js';
|
|
38
49
|
import './chunk-RA3O54FC.js';
|
|
39
50
|
import './chunk-M5POMKKW.js';
|
|
40
51
|
import './chunk-ZM2IMMYN.js';
|
|
52
|
+
import './chunk-FA2BOX4O.js';
|
|
41
53
|
import './chunk-XCCLFVXM.js';
|
|
42
54
|
import './chunk-BJ3KTMDH.js';
|
|
43
55
|
import './chunk-VNVZDWO3.js';
|
|
@@ -32,6 +32,9 @@ var DEFAULT_TIME_LIMIT_MINUTES = 480;
|
|
|
32
32
|
var DEFAULT_IDLE_LIMIT_MINUTES = 30;
|
|
33
33
|
var DEFAULT_BUILD = { memory: "8g", cpus: 4, pids: 4096, disk: "40g", variables: [] };
|
|
34
34
|
var BUILD_KEYS = ["memory", "cpus", "pids", "disk", "variables", "destinations", "allowHosts"];
|
|
35
|
+
var HOUSEKEEPING_KEYS = ["jobsKeepDays", "buildCacheMax", "minFreeDisk"];
|
|
36
|
+
var DEFAULT_JOBS_KEEP_DAYS = 30;
|
|
37
|
+
var DEFAULT_BUILD_CACHE_MAX = "20g";
|
|
35
38
|
var VARIABLE_NAME = /^[A-Za-z_][A-Za-z0-9_]{0,254}$/;
|
|
36
39
|
var MAX_VARIABLES = 100;
|
|
37
40
|
function defaultRunnerConfigPath(home = homeFromEnv()) {
|
|
@@ -77,6 +80,7 @@ var RUNNER_KEYS = [
|
|
|
77
80
|
"commands",
|
|
78
81
|
"hooks",
|
|
79
82
|
"build",
|
|
83
|
+
"housekeeping",
|
|
80
84
|
"autoUpdate"
|
|
81
85
|
];
|
|
82
86
|
function runnerNumbers() {
|
|
@@ -194,6 +198,7 @@ function loadRunnerConfig(configPath) {
|
|
|
194
198
|
if (!runner.hooks?.cleanup) fail(configPath, "runner.hooks.cleanup", "is required");
|
|
195
199
|
checkBuiltinHooks(configPath, runner.hooks);
|
|
196
200
|
const build = resolveBuild(configPath, runner.build);
|
|
201
|
+
const housekeeping = resolveHousekeeping(configPath, runner.housekeeping, build.disk);
|
|
197
202
|
if (config.scrub?.literals !== void 0 && !Array.isArray(config.scrub.literals)) {
|
|
198
203
|
fail(configPath, "scrub.literals", "must be a list of strings");
|
|
199
204
|
}
|
|
@@ -220,6 +225,7 @@ function loadRunnerConfig(configPath) {
|
|
|
220
225
|
report: runner.hooks.report
|
|
221
226
|
},
|
|
222
227
|
build,
|
|
228
|
+
housekeeping,
|
|
223
229
|
// A host with executables of its own for provision and cleanup chose
|
|
224
230
|
// its own environment, and an update could change what its hooks run
|
|
225
231
|
// under; it opts in. The built-in hooks are the runner's own. Provision
|
|
@@ -243,6 +249,37 @@ function checkBuiltinHooks(configPath, hooks) {
|
|
|
243
249
|
fail(configPath, "runner.hooks", `provision and cleanup must both be ${BUILTIN_CONTAINER}, both be ${BUILTIN_PROCESS}, both be ${BUILTIN_VM}, or neither`);
|
|
244
250
|
}
|
|
245
251
|
}
|
|
252
|
+
function resolveHousekeeping(configPath, block, buildDisk) {
|
|
253
|
+
const given = block ?? {};
|
|
254
|
+
if (typeof given !== "object" || Array.isArray(given)) fail(configPath, "runner.housekeeping", "must be an object");
|
|
255
|
+
const keys = given;
|
|
256
|
+
for (const key of Object.keys(keys)) {
|
|
257
|
+
if (HOUSEKEEPING_KEYS.includes(key)) continue;
|
|
258
|
+
const near = nearestKey(key, HOUSEKEEPING_KEYS);
|
|
259
|
+
fail(configPath, `runner.housekeeping.${key}`, near ? `is not a key this block accepts; did you mean ${near}?` : "is not a key this block accepts");
|
|
260
|
+
}
|
|
261
|
+
if (keys.jobsKeepDays !== void 0 && (!Number.isInteger(keys.jobsKeepDays) || keys.jobsKeepDays < 1)) {
|
|
262
|
+
fail(configPath, "runner.housekeeping.jobsKeepDays", "must be a whole number of at least 1");
|
|
263
|
+
}
|
|
264
|
+
let buildCacheMax;
|
|
265
|
+
if (keys.buildCacheMax === "off") {
|
|
266
|
+
buildCacheMax = "off";
|
|
267
|
+
} else {
|
|
268
|
+
const text = keys.buildCacheMax ?? DEFAULT_BUILD_CACHE_MAX;
|
|
269
|
+
const bytes = typeof text === "string" ? wholeBytes(parseSize(text)) : void 0;
|
|
270
|
+
if (bytes === void 0) fail(configPath, "runner.housekeeping.buildCacheMax", 'must be a size such as "20g", or "off"');
|
|
271
|
+
buildCacheMax = bytes;
|
|
272
|
+
}
|
|
273
|
+
const minText = keys.minFreeDisk ?? buildDisk;
|
|
274
|
+
const minFreeDisk = typeof minText === "string" ? wholeBytes(parseSize(minText)) : void 0;
|
|
275
|
+
if (minFreeDisk === void 0) fail(configPath, "runner.housekeeping.minFreeDisk", 'must be a size such as "40g"');
|
|
276
|
+
return { jobsKeepDays: keys.jobsKeepDays ?? DEFAULT_JOBS_KEEP_DAYS, buildCacheMax, minFreeDisk };
|
|
277
|
+
}
|
|
278
|
+
function wholeBytes(bytes) {
|
|
279
|
+
if (bytes === void 0) return void 0;
|
|
280
|
+
const whole = Math.floor(bytes);
|
|
281
|
+
return Number.isSafeInteger(whole) && whole > 0 ? whole : void 0;
|
|
282
|
+
}
|
|
246
283
|
function resolveBuild(configPath, block) {
|
|
247
284
|
if (block === void 0) return { ...DEFAULT_BUILD, variables: [] };
|
|
248
285
|
if (typeof block !== "object" || block === null || Array.isArray(block)) fail(configPath, "runner.build", "must be an object");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire } from 'node:module';
|
|
3
|
-
import { ArtifactTombstoneRecordSchema, ArtifactSpoolRecordSchema } from './chunk-
|
|
3
|
+
import { ArtifactTombstoneRecordSchema, ArtifactSpoolRecordSchema } from './chunk-ANK2B36Y.js';
|
|
4
4
|
import { homeFromEnv } from './chunk-VNVZDWO3.js';
|
|
5
5
|
import { mkdirSync, appendFileSync, writeFileSync, renameSync, existsSync, unlinkSync, readdirSync, readFileSync } from 'fs';
|
|
6
6
|
import { join, dirname } from 'path';
|