@amaster.ai/employee-runtime-connector 0.1.0-beta.38 → 0.1.0-beta.39
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.
|
@@ -4777,6 +4777,7 @@ import {
|
|
|
4777
4777
|
readdirSync as readdirSync5
|
|
4778
4778
|
} from "node:fs";
|
|
4779
4779
|
import { resolve as resolve7, sep } from "node:path";
|
|
4780
|
+
var defaultFs = { chmodSync: chmodSync3, chownSync, lchownSync, lstatSync: lstatSync4, readdirSync: readdirSync5 };
|
|
4780
4781
|
function defaultHashRunId(runId) {
|
|
4781
4782
|
return Number.parseInt(createHash5("sha256").update(runId).digest("hex").slice(0, 8), 16);
|
|
4782
4783
|
}
|
|
@@ -4791,23 +4792,24 @@ function isWithin(path, root) {
|
|
|
4791
4792
|
const normalizedRoot = resolve7(root);
|
|
4792
4793
|
return normalizedPath === normalizedRoot || normalizedPath.startsWith(`${normalizedRoot}${sep}`);
|
|
4793
4794
|
}
|
|
4794
|
-
function isolatePiChildPath(path, uid, gid) {
|
|
4795
|
+
function isolatePiChildPath(path, uid, gid, fs = defaultFs) {
|
|
4795
4796
|
const resolvedPath = resolve7(path);
|
|
4796
4797
|
const visit = (entryPath) => {
|
|
4797
|
-
const stat =
|
|
4798
|
+
const stat = fs.lstatSync(entryPath);
|
|
4798
4799
|
if (stat.isSymbolicLink()) {
|
|
4799
|
-
lchownSync(entryPath, uid, gid);
|
|
4800
|
+
fs.lchownSync(entryPath, uid, gid);
|
|
4800
4801
|
return;
|
|
4801
4802
|
}
|
|
4802
|
-
chownSync(entryPath, uid, gid);
|
|
4803
4803
|
if (stat.isDirectory()) {
|
|
4804
|
-
|
|
4805
|
-
for (const entry of
|
|
4804
|
+
fs.chmodSync(entryPath, 448);
|
|
4805
|
+
for (const entry of fs.readdirSync(entryPath)) {
|
|
4806
4806
|
visit(resolve7(entryPath, entry));
|
|
4807
4807
|
}
|
|
4808
|
+
fs.chownSync(entryPath, uid, gid);
|
|
4808
4809
|
return;
|
|
4809
4810
|
}
|
|
4810
|
-
|
|
4811
|
+
fs.chmodSync(entryPath, 384 | stat.mode & 73);
|
|
4812
|
+
fs.chownSync(entryPath, uid, gid);
|
|
4811
4813
|
};
|
|
4812
4814
|
visit(resolvedPath);
|
|
4813
4815
|
}
|
|
@@ -5611,7 +5613,7 @@ function readWorkspaceStatus(cwd, opts = {}) {
|
|
|
5611
5613
|
}
|
|
5612
5614
|
|
|
5613
5615
|
// src/amaster-runtime-daemon.mjs
|
|
5614
|
-
var CONNECTOR_VERSION = "0.1.0-beta.
|
|
5616
|
+
var CONNECTOR_VERSION = "0.1.0-beta.39";
|
|
5615
5617
|
var CONNECTOR_CONTRACT_VERSION = "2026-06-04.v1";
|
|
5616
5618
|
var MAX_CHECKPOINT_BYTES = 20 * 1024 * 1024;
|
|
5617
5619
|
var CHECKPOINT_TTL_MS = 24 * 60 * 60 * 1e3;
|
package/dist/amaster-runtime.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import { dirname, join, resolve } from "node:path";
|
|
|
5
5
|
import { homedir, hostname } from "node:os";
|
|
6
6
|
import { fileURLToPath } from "node:url";
|
|
7
7
|
|
|
8
|
-
const CONNECTOR_VERSION = "0.1.0-beta.
|
|
8
|
+
const CONNECTOR_VERSION = "0.1.0-beta.39";
|
|
9
9
|
|
|
10
10
|
const CAPABILITIES = [
|
|
11
11
|
"remote_registration",
|