@codesona/runner 0.0.0-stage → 0.1.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/LICENSE +19 -0
- package/README.md +77 -2
- package/THIRD-PARTY-NOTICES.txt +40 -0
- package/dist/cli.js +22259 -0
- package/dist/cli.js.LEGAL.txt +1 -0
- package/licenses/agent-session-driver/LICENSE +201 -0
- package/licenses/agent-session-driver/MODIFICATIONS.txt +42 -0
- package/licenses/signalr/LICENSE +23 -0
- package/licenses/ws/LICENSE +20 -0
- package/package.json +49 -4
package/LICENSE
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
Codesona Runner
|
|
2
|
+
Copyright (c) 2026 Azteron. All rights reserved.
|
|
3
|
+
|
|
4
|
+
You may install and run this software on machines you connect to a Codesona
|
|
5
|
+
workspace, for use with the Codesona service. You may not copy, modify,
|
|
6
|
+
distribute, sublicense or sell it, except as the terms you accepted for the
|
|
7
|
+
Codesona service or applicable law allow.
|
|
8
|
+
|
|
9
|
+
This package also contains third-party components that are licensed under
|
|
10
|
+
their own terms. THIRD-PARTY-NOTICES.txt lists them and says where each
|
|
11
|
+
licence is. Those terms, not this licence, govern those components.
|
|
12
|
+
|
|
13
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
14
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
15
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
16
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
17
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
18
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
19
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,3 +1,78 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Codesona Runner
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Codesona Runner runs your Codesona agents' sessions on a machine you own. The agent's turn, its
|
|
4
|
+
tools and its verdicts stay in Codesona; the coding agent CLI that does the work runs on your
|
|
5
|
+
machine, with your own account and your own model choice.
|
|
6
|
+
|
|
7
|
+
## Requirements
|
|
8
|
+
|
|
9
|
+
- macOS
|
|
10
|
+
- Node.js 20.9 or later
|
|
11
|
+
- Claude Code 2.1.306 or later, installed and logged in. Codex and Cursor are detected, and will be
|
|
12
|
+
supported later.
|
|
13
|
+
|
|
14
|
+
## Getting started
|
|
15
|
+
|
|
16
|
+
Copy the command Factory shows under Agents → Machines → Connect a machine and run it in a terminal:
|
|
17
|
+
|
|
18
|
+
```sh
|
|
19
|
+
codesona-runner start --machine-key csp_…
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
It pairs the machine, checks it (`doctor`), sets up the background service and waits until the
|
|
23
|
+
machine is connected. The service is a LaunchAgent (`~/Library/LaunchAgents/ai.codesona.runner.plist`):
|
|
24
|
+
it runs as you, starts at every login, and is started again if it stops unexpectedly.
|
|
25
|
+
|
|
26
|
+
After updating Codesona Runner, run `codesona-runner restart` once no session runs
|
|
27
|
+
(`codesona-runner status` shows them): the service starts again with the new version and connects
|
|
28
|
+
anew. While the service runs a session, `restart` leaves it alone, since a restart would end that
|
|
29
|
+
session, says how many it runs and to run it again once the service is idle; `restart --force`
|
|
30
|
+
restarts it all the same (it reports the sessions it ends to Codesona first). `codesona-runner doctor
|
|
31
|
+
--fix` restarts the service the same way, with the same care, when it finds it running an older
|
|
32
|
+
version. A service set up from another install (another Node.js or npm prefix) starts that install
|
|
33
|
+
again, and `restart` says so; `codesona-runner doctor --fix` sets the service up for the one you run.
|
|
34
|
+
|
|
35
|
+
## Commands
|
|
36
|
+
|
|
37
|
+
| Command | What it does |
|
|
38
|
+
|---|---|
|
|
39
|
+
| `codesona-runner start --machine-key <key>` | Pairs this machine with your workspace and sets up the background service. Options: `--url <url>` (an `https://` address), `--name <name>` (defaults to the machine's host name), `--no-service` (pair only; take sessions with `codesona-runner run`) |
|
|
40
|
+
| `codesona-runner run` | Keeps the machine connected and runs the sessions Codesona hands it, until you stop it (Ctrl-C). One per machine: not while the background service runs |
|
|
41
|
+
| `codesona-runner doctor` | Checks what this machine needs to run sessions: Node.js, the coding agent CLIs and Claude Code's login, Claude Code settings that would switch off Codesona's checks, the connection to Codesona, the clock, sleep settings and the background service. `--fix` puts right what needs no administrator (the background service only while it runs no session) and prints the exact `sudo` command for the rest |
|
|
42
|
+
| `codesona-runner status` | Shows whether this machine is connected, its agents and its sessions |
|
|
43
|
+
| `codesona-runner restart` | Restarts the background service (`launchctl kickstart -k`), so it runs the Codesona Runner installed now and connects anew, and waits until it is connected. Not while it runs sessions: it says how many and leaves it alone; `--force` restarts it all the same, ending them. With no background service set up, it says so: stop `codesona-runner run` (Ctrl-C) and run it again |
|
|
44
|
+
| `codesona-runner logout` | Disconnects this machine from Codesona, removes the background service and the Runner's files. If Codesona cannot be told, nothing is removed; `--local` removes this machine's side anyway (then disconnect it in Factory) |
|
|
45
|
+
| `codesona-runner --version` | Shows the version |
|
|
46
|
+
|
|
47
|
+
When it stops (logout, an update, the Mac shutting down), the Runner ends its sessions and reports
|
|
48
|
+
them to Codesona first. While a session runs it keeps the Mac awake; an idle Mac sleeps as you set it,
|
|
49
|
+
and its agents' runs wait for it. `codesona-runner doctor` says which power settings would let it
|
|
50
|
+
sleep or stay off, and the command that changes them.
|
|
51
|
+
|
|
52
|
+
## What it keeps on the machine
|
|
53
|
+
|
|
54
|
+
Everything is under `~/.codesona-runner/` (only you can read it):
|
|
55
|
+
|
|
56
|
+
- `config.json`: the machine's key, which changes every time the Runner connects (and at least once
|
|
57
|
+
a day). The keys for the connection, for each agent and for each session live only in the running
|
|
58
|
+
Runner's memory.
|
|
59
|
+
- `agents/<agent>/`: each agent's working directory, with the instructions, skills and settings of
|
|
60
|
+
its sessions. Your coding agent CLI keeps its transcripts where it always does (`~/.claude`).
|
|
61
|
+
- `outbox/`, `spool/`, `state/`: results and activity not yet delivered to Codesona, and what
|
|
62
|
+
`codesona-runner status` shows. The background service's log is `state/runner.log`.
|
|
63
|
+
|
|
64
|
+
Sessions run with your own account, settings and model: the CLI gets your environment, without
|
|
65
|
+
any of Codesona's keys in it. The background service runs with the PATH it was set up with (node's
|
|
66
|
+
own directory, `/opt/homebrew/bin`, `~/.local/bin`, `/usr/local/bin` and the system's) and none of
|
|
67
|
+
your shell's variables: a `CLAUDE_CODE_OAUTH_TOKEN`, `ANTHROPIC_API_KEY` or `CLAUDE_CONFIG_DIR`
|
|
68
|
+
exported in your shell profile does not reach its sessions. Log Claude Code in with
|
|
69
|
+
`claude auth login` (the login is kept in your keychain) and keep its settings in `~/.claude`;
|
|
70
|
+
`codesona-runner doctor` checks the login as the service's sessions will have it, and says which of
|
|
71
|
+
those variables your shell sets. With no background service set up (`start --no-service`, then
|
|
72
|
+
`codesona-runner run` in a terminal), it checks your terminal's own login as well, and the settings
|
|
73
|
+
in the `CLAUDE_CONFIG_DIR` your terminal names.
|
|
74
|
+
|
|
75
|
+
## Licence
|
|
76
|
+
|
|
77
|
+
Codesona Runner is licensed under the terms in `LICENSE`. It contains third-party components under
|
|
78
|
+
their own licences; `THIRD-PARTY-NOTICES.txt` lists them.
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
Third-party software in Codesona Runner
|
|
2
|
+
|
|
3
|
+
Codesona Runner (the @codesona/runner package) contains the third-party
|
|
4
|
+
components listed below. Each one is licensed under its own terms, and those
|
|
5
|
+
terms govern that component.
|
|
6
|
+
|
|
7
|
+
--------------------------------------------------------------------------------
|
|
8
|
+
|
|
9
|
+
Agent session driver
|
|
10
|
+
|
|
11
|
+
Where: portions of dist/cli.js
|
|
12
|
+
Licence: Apache License 2.0. The full text and the original copyright
|
|
13
|
+
notice are in licenses/agent-session-driver/LICENSE.
|
|
14
|
+
Changes: modified by Azteron; see
|
|
15
|
+
licenses/agent-session-driver/MODIFICATIONS.txt. The modification
|
|
16
|
+
notices carried by its source files are collected in
|
|
17
|
+
dist/cli.js.LEGAL.txt.
|
|
18
|
+
|
|
19
|
+
--------------------------------------------------------------------------------
|
|
20
|
+
|
|
21
|
+
ASP.NET Core SignalR client (@microsoft/signalr 10.0.11)
|
|
22
|
+
|
|
23
|
+
Where: portions of dist/cli.js (the hub connection)
|
|
24
|
+
Licence: MIT License. Copyright (c) .NET Foundation and Contributors. The
|
|
25
|
+
full text is in licenses/signalr/LICENSE.
|
|
26
|
+
Changes: none to its code. The bundle's build turns off one run-time load
|
|
27
|
+
of its optional Node.js dependencies, which the Runner supplies
|
|
28
|
+
itself (scripts/build.mjs).
|
|
29
|
+
|
|
30
|
+
--------------------------------------------------------------------------------
|
|
31
|
+
|
|
32
|
+
ws (ws 8.22.0), a WebSocket client for Node.js
|
|
33
|
+
|
|
34
|
+
Where: portions of dist/cli.js (the hub connection's socket)
|
|
35
|
+
Licence: MIT License. Copyright (c) 2011 Einar Otto Stangvik, (c) 2013
|
|
36
|
+
Arnout Kazemier and contributors, (c) 2016 Luigi Pinca and
|
|
37
|
+
contributors. The full text is in licenses/ws/LICENSE.
|
|
38
|
+
Changes: none.
|
|
39
|
+
|
|
40
|
+
--------------------------------------------------------------------------------
|