Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Clone

Read only, no credentials:

https://rodent.software/git/vole.git

Write over SSH with a registered key:

git clone ssh://git@0.0.0.0:2222/vole.git

A free and open-source forge that lives in your Git repo.

Give a job a credential for the bot it acts as

6e1fca5115b709d31eeb51864b187d79aa104e5f · Keenan Nemetz · 6d ago · parent 446542e6

Give a job a credential for the bot it acts as

A workflow can name a bot account with `bot:`. When the job is leased the
instance generates a key for that run, stores the public half with the run,
repository and expiry, and sends the private half on the lease channel. The
runner writes it into the job's run directory with a known_hosts entry for the
instance, so a step's `git push` or `vole issue comment` authenticates as the
account and nothing has to be wired per job.

The account's role is the permission, in full. The credential replaces exactly one
requirement — that writing to the issues branch needs `maintain` — and adds no rule
of its own. What a job may write there is what its account may do, asked the same
way the browser asks: discuss, file an issue, manage an item it wrote, open a
change from a branch it may push, triage and approve when the role allows it. Those
are the ACL's own capabilities (`CanDiscuss`, `CanOpenRequest`, `CanTriage`,
`CanApprove`), so a maintainer's job may do everything a maintainer's key may do,
including labels, states, and other people's items.

A session is scoped only when the fingerprint it authenticated with is a live
credential row; an expired one reads as absent, so the push falls back to the
account's own role and is refused where a contribute account cannot write.

Two things end the key: the run finishing, which drops the row, and the expiry,
which is what stops a credential whose runner was killed and never reported. The
key is also masked in the log like a secret, since a step that cats it should not
leave it in the attempt.

Closes #165.

docs/workflows.md +21−2

@@ -157,12 +157,22 @@ on:
157 157 issue:
158 158 types: [opened, assigned]
159 159 assigned-to: [coding-agent]
160 author:
161 role: maintain
160 162 comment:
161 163 types: [created]
162 164 mentioned: [coding-agent]
163 165 replied-to: [coding-agent]
164 166 author:
165 167 role: maintain
168 jobs:
169 agent:
170 image-file: agent
171 network: bridge
172 timeout: 2h
173 bot: coding-agent
174 steps:
175 - run: run-the-session
166 176 ```
167 177
168 178 `mentioned` matches an `@coding-agent` in the issue, comment, or change body.
@@ -178,8 +188,17 @@ not start it again. Mentions inside code samples are ignored. See
178 188 for the exact rules.
179 189
180 190 The job acts as an account, so the account it uses should be a bot: it has no
181 browser sign-in and is shown as a bot wherever its name appears. See
182 [Accounts and access § Bot accounts](accounts-and-access.md#bot-accounts).
191 browser sign-in and is shown as a bot wherever its name appears. `bot:` names it, and
192 the instance gives the job a credential for that account when it is leased — one
193 run's key, written into the job, gone when the run ends — so a comment or a change it
194 writes is attributable and needs no long-lived key in a repository secret. The
195 account's role still decides what it may do. See
196 [Accounts and access § Bot accounts](accounts-and-access.md#bot-accounts) and
197 [Workflow reference § bot](reference/workflow-reference.md#bot).
198
199 `network: bridge` is there because the session calls a model; `timeout` because a
200 session can run longer than the ten-minute step default. A job that runs unattended
201 should have both.
183 202
184 203 A comment body is still untrusted text. If the job can write — comment, push a
185 204 branch, or open a change — use `author.role: maintain` or `author.name` to limit who