@rivet-dev/agentos 0.0.0-agentos-dylib-plugin.bbfdf95 → 0.0.0-codex-darwin-ci-publish.61a7af3
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/dist/actor.js +30 -0
- package/dist/plugin-binary.js +7 -1
- package/package.json +7 -4
package/dist/actor.js
CHANGED
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* config envelope across the bridge — it owns no agent-os runtime logic.
|
|
11
11
|
*/
|
|
12
12
|
import { sep } from "node:path";
|
|
13
|
+
import common from "@agent-os-pkgs/common";
|
|
13
14
|
import { getSidecarPath } from "@rivet-dev/agentos-sidecar";
|
|
14
15
|
import { actor, } from "rivetkit";
|
|
15
16
|
import { agentOsActorConfigSchema, } from "./config.js";
|
|
@@ -84,6 +85,22 @@ function withAutoAgentNodeModulesMount(mounts, descriptors) {
|
|
|
84
85
|
const [hostNodeModulesDir] = [...roots];
|
|
85
86
|
return [...(mounts ?? []), nodeModulesMount(hostNodeModulesDir)];
|
|
86
87
|
}
|
|
88
|
+
/**
|
|
89
|
+
* Stable identity for a software descriptor, used to de-duplicate the
|
|
90
|
+
* auto-injected default bundle against software the caller passed explicitly.
|
|
91
|
+
* Resolved `commandDir`/`packageDir` paths are the most reliable key; `name`
|
|
92
|
+
* is the fallback for descriptors without a directory.
|
|
93
|
+
*/
|
|
94
|
+
function softwareIdentity(d) {
|
|
95
|
+
if (typeof d.commandDir === "string")
|
|
96
|
+
return `dir:${d.commandDir}`;
|
|
97
|
+
if (typeof d.packageDir === "string")
|
|
98
|
+
return `dir:${d.packageDir}`;
|
|
99
|
+
const name = d.name;
|
|
100
|
+
if (typeof name === "string")
|
|
101
|
+
return `name:${name}`;
|
|
102
|
+
return JSON.stringify(d);
|
|
103
|
+
}
|
|
87
104
|
function flattenSoftware(input, out) {
|
|
88
105
|
if (input == null)
|
|
89
106
|
return;
|
|
@@ -98,6 +115,19 @@ function flattenSoftware(input, out) {
|
|
|
98
115
|
export function buildConfigJson(parsed) {
|
|
99
116
|
const descriptors = [];
|
|
100
117
|
flattenSoftware(parsed.options?.software, descriptors);
|
|
118
|
+
// Auto-include the default software bundle (`@agent-os-pkgs/common`: `sh` +
|
|
119
|
+
// coreutils + the standard CLI tools agents rely on) unless the caller opted
|
|
120
|
+
// out with `defaultSoftware: false`. Anything already listed in `software`
|
|
121
|
+
// (e.g. an explicit `common`) is not duplicated. Prepended so the baseline
|
|
122
|
+
// tools come first, matching the previous explicit `[common, ...]` ordering.
|
|
123
|
+
const defaultSoftwareEnabled = parsed.options?.defaultSoftware !== false;
|
|
124
|
+
if (defaultSoftwareEnabled) {
|
|
125
|
+
const defaults = [];
|
|
126
|
+
flattenSoftware(common, defaults);
|
|
127
|
+
const seen = new Set(descriptors.map(softwareIdentity));
|
|
128
|
+
const toPrepend = defaults.filter((d) => !seen.has(softwareIdentity(d)));
|
|
129
|
+
descriptors.unshift(...toPrepend);
|
|
130
|
+
}
|
|
101
131
|
const software = [];
|
|
102
132
|
for (const d of descriptors) {
|
|
103
133
|
if (typeof d.commandDir === "string") {
|
package/dist/plugin-binary.js
CHANGED
|
@@ -34,6 +34,12 @@ function getPlatformPackageName() {
|
|
|
34
34
|
if (arch === "arm64")
|
|
35
35
|
return "@rivet-dev/agentos-plugin-linux-arm64-gnu";
|
|
36
36
|
break;
|
|
37
|
+
case "darwin":
|
|
38
|
+
if (arch === "arm64")
|
|
39
|
+
return "@rivet-dev/agentos-plugin-darwin-arm64";
|
|
40
|
+
if (arch === "x64")
|
|
41
|
+
return "@rivet-dev/agentos-plugin-darwin-x64";
|
|
42
|
+
break;
|
|
37
43
|
default:
|
|
38
44
|
break;
|
|
39
45
|
}
|
|
@@ -65,7 +71,7 @@ export function getPluginPath() {
|
|
|
65
71
|
const platformPkg = getPlatformPackageName();
|
|
66
72
|
if (!platformPkg) {
|
|
67
73
|
throw new Error(`@rivet-dev/agentos: unsupported platform ${process.platform}/${process.arch}. ` +
|
|
68
|
-
"The Agent OS actor plugin currently supports linux x64 and arm64. " +
|
|
74
|
+
"The Agent OS actor plugin currently supports linux x64/arm64 and macOS x64/arm64. " +
|
|
69
75
|
`Set ${PLUGIN_BIN_ENV} to a local cdylib to override.`);
|
|
70
76
|
}
|
|
71
77
|
const require = createRequire(import.meta.url);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rivet-dev/agentos",
|
|
3
|
-
"version": "0.0.0-
|
|
3
|
+
"version": "0.0.0-codex-darwin-ci-publish.61a7af3",
|
|
4
4
|
"description": "Agent OS actor for RivetKit — thin TS forwarder that loads the native actor plugin (cdylib) via RivetKit's generic native-plugin ABI.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -28,8 +28,9 @@
|
|
|
28
28
|
"test": "vitest run"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@
|
|
32
|
-
"@rivet-dev/agentos-
|
|
31
|
+
"@agent-os-pkgs/common": "0.0.0-split-runtime-preview.5d46b14",
|
|
32
|
+
"@rivet-dev/agentos-core": "0.0.0-codex-darwin-ci-publish.61a7af3",
|
|
33
|
+
"@rivet-dev/agentos-sidecar": "0.0.0-codex-darwin-ci-publish.61a7af3",
|
|
33
34
|
"zod": "^4.1.11"
|
|
34
35
|
},
|
|
35
36
|
"peerDependencies": {
|
|
@@ -44,6 +45,8 @@
|
|
|
44
45
|
"node": ">=20"
|
|
45
46
|
},
|
|
46
47
|
"optionalDependencies": {
|
|
47
|
-
"@rivet-dev/agentos-plugin-
|
|
48
|
+
"@rivet-dev/agentos-plugin-darwin-arm64": "0.0.0-codex-darwin-ci-publish.61a7af3",
|
|
49
|
+
"@rivet-dev/agentos-plugin-darwin-x64": "0.0.0-codex-darwin-ci-publish.61a7af3",
|
|
50
|
+
"@rivet-dev/agentos-plugin-linux-x64-gnu": "0.0.0-codex-darwin-ci-publish.61a7af3"
|
|
48
51
|
}
|
|
49
52
|
}
|