relayrunner 0.6.0 → 0.8.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 +49 -1
- package/dist/cli.js +947 -124
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -32,7 +32,7 @@ stops working, so a copy of `machine.json` from a backup or a synced dotfiles
|
|
|
32
32
|
folder can't sign in as the machine.
|
|
33
33
|
|
|
34
34
|
While it runs, the machine is online: it keeps a WebSocket open to the gateway,
|
|
35
|
-
runs the jobs it's sent
|
|
35
|
+
runs the jobs it's sent and prints what happens, including the
|
|
36
36
|
repo each job is from. It reconnects on its own if the connection drops. Ctrl-C
|
|
37
37
|
takes it offline; a job that's running stops with it. Press `p` to pause or
|
|
38
38
|
resume it without going offline (see `relayrunner pause`). The terminal tab's
|
|
@@ -58,6 +58,29 @@ approved the machine also gets an email, since someone else may have its token.
|
|
|
58
58
|
one is set, otherwise the Mac's Computer Name from System Settings).
|
|
59
59
|
- `--share only-me|anyone` sets who can run jobs on this machine without asking.
|
|
60
60
|
It works on a machine that's already signed in too.
|
|
61
|
+
- `--concurrency <n>` sets how many jobs it runs at once. The default is 2 on a
|
|
62
|
+
computer with 8 or more CPU cores, otherwise 1, and `connect` prints it. Each
|
|
63
|
+
slot runs its jobs in its own copy of the runner,
|
|
64
|
+
`~/.relayrunner/runner/<version>/slot-<n>/`, made when `connect` starts (a
|
|
65
|
+
copy-on-write clone where the disk supports it). With more than one slot,
|
|
66
|
+
each line of a job's output starts with its slot, such as `[slot 2]`.
|
|
67
|
+
- `--isolated` (experimental) runs each job in its own Linux VM, so a job can't
|
|
68
|
+
read your files or the machine token. It needs a Mac with Apple silicon,
|
|
69
|
+
macOS 26 and Apple's [container](https://github.com/apple/container/releases)
|
|
70
|
+
tool, started with `container system start`. Each VM starts from GitHub's
|
|
71
|
+
runner image with nothing mounted and is deleted when the job ends. Jobs run
|
|
72
|
+
on Linux arm64, and Docker works in them. `connect` builds the job image
|
|
73
|
+
once per runner version.
|
|
74
|
+
- A firewall in the VM lets the job reach the internet but not your Mac or
|
|
75
|
+
your local network. It guards against accidents: a job that sets out to
|
|
76
|
+
remove it can, through Docker. `--local-network` turns the firewall off,
|
|
77
|
+
for jobs that need something on your network.
|
|
78
|
+
- `--image <image>` starts from another runner image.
|
|
79
|
+
- `connect` removes the images it downloaded or built for older runner
|
|
80
|
+
versions. It never removes images you got yourself.
|
|
81
|
+
- `~/.relayrunner/isolated.log` records each `container` command and its
|
|
82
|
+
result, never a job's output or credentials. Send it along when you report
|
|
83
|
+
a problem.
|
|
61
84
|
- If the machine is removed in the dashboard, `connect` deletes the saved token.
|
|
62
85
|
A running `connect` exits and asks you to run it again; a new one signs in
|
|
63
86
|
straight away.
|
|
@@ -68,6 +91,10 @@ this machine?": Only me, or Anyone in your workspaces (teammates' and bots' jobs
|
|
|
68
91
|
too). It doesn't ask when you're alone in all of them, on later runs, or without
|
|
69
92
|
a terminal to answer. [`relayrunner share`](#relayrunner-share) changes it later.
|
|
70
93
|
|
|
94
|
+
When you approve the machine in the browser, you pick which of your workspaces it
|
|
95
|
+
runs jobs in. `connect` then prints them with `Change with: relayrunner workspaces`
|
|
96
|
+
([`relayrunner workspaces`](#relayrunner-workspaces)).
|
|
97
|
+
|
|
71
98
|
Run inside a checkout of a private repo where no job uses RelayRunner yet,
|
|
72
99
|
`connect` first asks whether to set it up (default no). Yes runs the same picker
|
|
73
100
|
as [`relayrunner init`](#relayrunner-init). No is remembered for that repo in
|
|
@@ -173,6 +200,27 @@ It's the same setting as the sharing icon on the machine's card on the Runners
|
|
|
173
200
|
page, and only the machine's owner can change it there. `relayrunner whoami`
|
|
174
201
|
shows it too. Exits 1 when not signed in or when the token is no longer valid.
|
|
175
202
|
|
|
203
|
+
## `relayrunner workspaces`
|
|
204
|
+
|
|
205
|
+
```sh
|
|
206
|
+
npx relayrunner workspaces # list the ones it's in and the ones it isn't
|
|
207
|
+
npx relayrunner workspaces add acme # run jobs from Acme here too
|
|
208
|
+
npx relayrunner workspaces remove acme # stop running Acme's jobs here
|
|
209
|
+
```
|
|
210
|
+
|
|
211
|
+
Which of your workspaces this machine runs jobs in, the same choice as the
|
|
212
|
+
"Run jobs in" checkboxes when you approve it. `list` (the default) shows the
|
|
213
|
+
workspaces it's in, the ones it isn't, and its sharing; `--json` prints the same
|
|
214
|
+
as JSON. `add` and `remove` take a workspace's name or slug in any case, or its
|
|
215
|
+
id when two have the same name. Leave the name out in a terminal to pick from a
|
|
216
|
+
list.
|
|
217
|
+
|
|
218
|
+
Adding a workspace while the machine is set to `anyone` warns that anyone who can
|
|
219
|
+
push to that workspace's private repos can run jobs on it. Removing the last one
|
|
220
|
+
leaves the machine connected but taking no jobs until you add one back. Exits 1
|
|
221
|
+
when not signed in, when the token is no longer valid, or when no workspace has
|
|
222
|
+
that name.
|
|
223
|
+
|
|
176
224
|
## Building
|
|
177
225
|
|
|
178
226
|
`pnpm --filter relayrunner build` bundles the CLI into `dist/cli.js` with
|