relayrunner 0.1.1 → 0.2.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/README.md +47 -31
- package/dist/cli.js +1110 -126
- package/package.json +13 -6
- package/dist/SKILL.md +0 -15
- package/dist/routing.js +0 -74
- package/dist/runner.js +0 -152
- package/dist/system.js +0 -41
- package/dist/workflows.js +0 -109
package/README.md
CHANGED
|
@@ -1,48 +1,64 @@
|
|
|
1
|
-
# RelayRunner
|
|
1
|
+
# RelayRunner CLI
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
Connects a machine to the RelayRunner gateway so it can run your workspace's
|
|
4
|
+
GitHub Actions jobs. See [#61](https://github.com/relayrunner/relayrunner/issues/61)
|
|
5
|
+
for the plan.
|
|
5
6
|
|
|
6
|
-
##
|
|
7
|
+
## `relayrunner connect`
|
|
7
8
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
Paste this into your agent from the checkout you want to set up:
|
|
11
|
-
|
|
12
|
-
```text
|
|
13
|
-
Set up RelayRunner in this checkout using https://raw.githubusercontent.com/atticoos/RelayRunner/main/docs/agent-install.md
|
|
9
|
+
```sh
|
|
10
|
+
npx relayrunner connect
|
|
14
11
|
```
|
|
15
12
|
|
|
16
|
-
|
|
13
|
+
The first run signs you in: it shows a code and opens the dashboard, where you
|
|
14
|
+
pick the workspace and name for this machine and approve. The machine token is
|
|
15
|
+
saved to `~/.relayrunner/machine.json` (mode 0600); later runs reuse it.
|
|
17
16
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
17
|
+
While it runs, the machine is online: it keeps a WebSocket open to the gateway,
|
|
18
|
+
runs the jobs it's sent (one at a time) and prints what happens. It reconnects
|
|
19
|
+
on its own if the connection drops. Ctrl-C takes it offline; a job that's
|
|
20
|
+
running stops with it.
|
|
22
21
|
|
|
23
|
-
|
|
24
|
-
|
|
22
|
+
- `--server <url>` or `RELAYRUNNER_URL` points it at another gateway. Changing it signs in again.
|
|
23
|
+
- `--name <name>` changes the suggested machine name (default: the hostname).
|
|
24
|
+
- If the machine is removed in the dashboard, `connect` deletes the saved token.
|
|
25
|
+
A running `connect` exits and asks you to run it again; a new one signs in
|
|
26
|
+
straight away.
|
|
25
27
|
|
|
26
|
-
|
|
28
|
+
Jobs run in `actions/runner`, which is downloaded into
|
|
29
|
+
`~/.relayrunner/runner/<version>` on first connect and checked against its
|
|
30
|
+
SHA-256. Set `RELAYRUNNER_HOME` to keep everything somewhere else.
|
|
27
31
|
|
|
28
|
-
|
|
32
|
+
## `relayrunner whoami`
|
|
29
33
|
|
|
30
|
-
```
|
|
31
|
-
|
|
34
|
+
```sh
|
|
35
|
+
npx relayrunner whoami
|
|
32
36
|
```
|
|
33
37
|
|
|
34
|
-
|
|
35
|
-
|
|
38
|
+
Asks the gateway who the saved machine token belongs to and prints the machine,
|
|
39
|
+
its workspace, who enrolled it (name and email) and whether it's online now.
|
|
40
|
+
|
|
41
|
+
- Not signed in: says so and exits 1.
|
|
42
|
+
- Removed from the workspace (or the token is no longer valid): says so and
|
|
43
|
+
exits 1. The saved token is left alone; the next `connect` replaces it.
|
|
44
|
+
- Gateway unreachable: prints what's saved locally, marked unverified, and exits 0.
|
|
45
|
+
- `--json` prints the same as JSON (never the token). `--server <url>` or
|
|
46
|
+
`RELAYRUNNER_URL` only reports a sign-in for that gateway.
|
|
47
|
+
|
|
48
|
+
## `relayrunner pause` and `relayrunner resume`
|
|
36
49
|
|
|
37
50
|
```sh
|
|
38
|
-
relayrunner
|
|
39
|
-
relayrunner
|
|
51
|
+
npx relayrunner pause
|
|
52
|
+
npx relayrunner resume
|
|
40
53
|
```
|
|
41
54
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
55
|
+
Pausing stops new jobs routing to this machine while it stays connected and
|
|
56
|
+
enrolled. A job it's already running finishes. `resume` lets jobs route here
|
|
57
|
+
again. Anyone in the workspace can do the same from the machine's ⋯ menu on the
|
|
58
|
+
Runners page, and a running `relayrunner connect` prints when that happens.
|
|
59
|
+
Both exit 1 when not signed in or when the token is no longer valid.
|
|
60
|
+
|
|
61
|
+
## Building
|
|
45
62
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
skill installation, repository setup, and switching runners.
|
|
63
|
+
`pnpm --filter relayrunner build` bundles the CLI into `dist/cli.js` with
|
|
64
|
+
tsdown, including the workspace's `@relayrunner/machine-protocol` package.
|