nandi/oripublic Fork 0
b6cd929ab1425a4ef6073ea9c189917cca02cf3c
Commits
Clone
git clone https://git.rickub.com/nandi/ori.git
git clone ssh://git@rickub.com/nandi/ori.git

Host key fingerprint (ed25519): SHA256:iycHnxEyq0Q7uyVpB7JlznP0G7JrTPXLYRcAU5CSLhc — verify it before your first connect.

forked from bots-garden/ori

spec.yaml · 88 lines · 3.8 KBYAML Blame HistoryRaw
🛟 Updated. 55d4c9e k33g 20h ago1schemaVersion: "2"
2kind: mixin
3name: ori
4displayName: Ori — ACP web client for Claude Code
5description: >
6 Starts the ori web server inside the sandbox. Ori is a browser client for
7 ACP (Agent Client Protocol) code agents: a Go backend serves a React SPA
8 (Zed-style agent panel: streamed answers, thoughts, tool calls, plans,
9 permission prompts) plus a workspace panel (file tree with Material icons,
10 Monaco preview/editor with rendered Markdown and AsciiDoc, interactive
11 terminal). This kit only launches and describes the server; the binaries
12 ship in the k33g/ori template image (template/Dockerfile in the ori
13 repository), so use it together with `--template k33g/ori:0.0.1`.
14licenses:
15 - MIT
16
17# This mixin only makes sense composed with the claude agent kit: the server
18# it starts drives Claude Code through the claude-code-acp adapter, and the
19# Anthropic credentials/egress come from that kit.
20requires:
21 agent: claude
22
23args:
24 port:
25 default: "8888"
26 description: TCP port the ori server listens on inside the sandbox
27 pattern: "^[0-9]{2,5}$"
28
29# No extra network permissions: the Anthropic endpoints come from the claude
30# agent kit this mixin composes with, and the ACP adapter is baked into the
31# template image, so nothing is downloaded at runtime.
32
33# Auto-publishes an ephemeral localhost port at create (the create output
34# prints it: "Published web: localhost:<port> -> <port>/tcp"). Pin a fixed
35# host port instead with `-p 8888:8888` at create or `sbx ports … --publish`.
36# The unquoted arg reference decodes as the integer the schema expects.
37ports:
38 - container: ${{ kit.args.port }}
39 protocol: tcp
40 name: web
41
42setup:
43 startup:
44 # Startup commands run on every container start through the detached
45 # dispatcher, so the pgrep guard makes this idempotent. The server binds
46 # 0.0.0.0 (empty host in --addr) so published ports reach it from the
47 # host's browser. `user` is omitted: startup commands default to uid 1000,
48 # the agent user.
49 #
50 # The PATH export is load-bearing: the dispatcher runs this via
51 # `su -s /bin/sh -c … agent`, and su resets PATH to the login.defs
52 # default — which does not contain the npm prefix where claude-code-acp
53 # lives, nor ~/.local/bin where claude does.
54 - command:
55 - "sh"
56 - "-c"
57 - |
58 export PATH="/usr/local/share/npm-global/bin:/home/agent/.local/bin:$PATH"
59 pgrep -x ori >/dev/null 2>&1 && exit 0
60 nohup /usr/local/bin/ori \
61 --addr ":${{ kit.args.port }}" \
62 --agent-cmd claude-code-acp \
63 --cwd "${WORKSPACE_DIR:-/home/agent/workspace}" \
64 >> /home/agent/.ori.log 2>&1 &
65 description: Start the ori web server (idempotent)
66
67agentInstructions:
68 content: |
69 ## Ori web server (kit `ori`)
70
71 This sandbox runs **ori**, a web client for Claude Code over ACP. It was
72 started automatically and serves on **port ${{ kit.args.port }}** (all
73 interfaces).
74
75 - Binaries: `/usr/local/bin/ori` (server) and `/usr/local/bin/ori-mock-agent`
76 (a deterministic demo ACP agent that needs no credentials).
77 - Log file: `/home/agent/.ori.log`.
78 - The server drives its own Claude Code session through the
79 `claude-code-acp` adapter (preinstalled); credentials are injected by the
80 sandbox proxy, so no login is needed inside the container.
81 - Restart it with:
82 `pkill -x ori; nohup ori --addr ":${{ kit.args.port }}" --agent-cmd claude-code-acp --cwd "$PWD" >> /home/agent/.ori.log 2>&1 &`
83 - To demo without consuming Claude usage, restart it with
84 `--agent-cmd ori-mock-agent` instead.
85
86 A localhost port for the UI was published on the host at create time (see
87 the create output); the human can pin a different one with
88 `sbx ports <sandbox-name> --publish <host-port>:${{ kit.args.port }}/tcp`.