vole
Site
Clone
Read only, no credentials:
https://rodent.software/vole.git
Write over SSH with a registered key:
git clone ssh://git@rodent.software/vole.git
Self-hosted forge that lives in your Git repo.
Move release channels to an authoritative channels.db
262e516e838cfc4b16b5d00fd98d5e4ef135aa85 · Keenan Nemetz · 19d ago · parent 24019cb3
Move release channels to an authoritative channels.db Channels are consumed from the public URL and are server-side publication state, so they no longer live on the vole branch or in the derived index. - forge/channel: authoritative SQLite store with schema, validation, and CRUD - config: data/channels.db, opened and closed with the instance - CLI: release channel set|list|clear over a new vole-channel SSH verb - server: maintain for set/clear, read for list, annotated-tag validation, audit channel.set/channel.clear, JSON list - web: channel page and tree read the store; release badges query it - remove the metadata-branch channel parser/validator, the index-derived channel table, and the hook path rules - backup, instance-data, and architecture docs include channels.db Refs: 01M7BPHANWMSW5HK2GT0PY74QZ
server/ssh/server.go +13−1
| @@ -32,6 +32,7 @@ import ( | |||
| 32 | 32 | "rodent.software/vole/core/lfs" | |
| 33 | 33 | "rodent.software/vole/forge" | |
| 34 | 34 | "rodent.software/vole/forge/access" | |
| 35 | "rodent.software/vole/forge/channel" | ||
| 35 | 36 | "rodent.software/vole/forge/identity" | |
| 36 | 37 | "rodent.software/vole/forge/repo" | |
| 37 | 38 | ) | |
| @@ -82,6 +83,9 @@ type Config struct { | |||
| 82 | 83 | IndexDB string | |
| 83 | 84 | // Runs is the CI queue, served to runners over the vole-runner verb. | |
| 84 | 85 | Runs *runs.Store | |
| 86 | // Channels is the authoritative release-channel store; the CLI asks for it | ||
| 87 | // over the vole-channel verb. | ||
| 88 | Channels *channel.Store | ||
| 85 | 89 | // LFS is the object store behind git-lfs-transfer. | |
| 86 | 90 | LFS *lfs.Store | |
| 87 | 91 | // Logs holds one file per CI attempt, streamed from the runner. | |
| @@ -588,6 +592,14 @@ func (s *Server) exec(ch xssh.Channel, req *xssh.Request, command, user, fp, rem | |||
| 588 | 592 | exit(ch, s.serveSecret(ch, argv, user)) | |
| 589 | 593 | return | |
| 590 | 594 | } | |
| 595 | // Release channels are server-side state, so the CLI asks the instance for | ||
| 596 | // them over the same key it pushes with. The verbs re-check the repository | ||
| 597 | // role and record the move in the audit log. | ||
| 598 | if len(argv) >= 1 && argv[0] == "vole-channel" { | ||
| 599 | req.Reply(true, nil) | ||
| 600 | exit(ch, s.serveChannel(ch, argv, user)) | ||
| 601 | return | ||
| 602 | } | ||
| 591 | 603 | // The admin API is a fixed command set, not a shell. It is available only to | |
| 592 | 604 | // accounts marked as instance admins. | |
| 593 | 605 | if len(argv) >= 1 && argv[0] == "vole-admin" { | |
| @@ -643,7 +655,7 @@ func (s *Server) exec(ch xssh.Channel, req *xssh.Request, command, user, fp, rem | |||
| 643 | 655 | return | |
| 644 | 656 | } | |
| 645 | 657 | if len(argv) != 2 { | |
| 646 | refuse("only git-upload-pack, git-receive-pack, vole-admin, vole-roster, vole-whoami, vole-runner, vole-change-merge, vole-change-status, vole-run-list, vole-run-show, vole-run-log, vole-run-cancel, vole-run-rerun and vole-workflow-dispatch are available") | ||
| 658 | refuse("only git-upload-pack, git-receive-pack, vole-admin, vole-roster, vole-whoami, vole-runner, vole-change-merge, vole-change-status, vole-run-list, vole-run-show, vole-run-log, vole-run-cancel, vole-run-rerun, vole-workflow-dispatch and vole-channel are available") | ||
| 647 | 659 | return | |
| 648 | 660 | } | |
| 649 | 661 | verb := argv[0] | |