Repository navigation
Support the yank and delete roles - #15
Merged
Merged
Conversation
The registry can now give an account the `yank` and/or `delete` role with its own grants, without making it an admin. Teach the API models about the new roles (`yank_grants`, `delete_grants`, `access.yank`, `access.delete`), show the grants in `sreg whoami`, and document that `sreg yank` and `sreg delete` accept such credentials. docs/spec.md and docs/api.md are synced from the Worker. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TECh4WQ5Nukqo7g4pr8pha
docs/api.md and docs/spec.md are copies of the Worker's: yank and delete only accounts can now sign in to the panel. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TECh4WQ5Nukqo7g4pr8pha
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The registry can now give an account the
yankand/ordeleterole with its own grants, without making it an admin (see kduma-OSS/serverless-registry-worker#31). This teachessregabout them.yank_grants/delete_grantson credentials and requests,access.yank/access.deleteinwhoami.sreg whoamilists the yank and delete grants.sreg yankandsreg deletealready worked with any token; the README now says they accept a credential with the matching role whose grants cover the version.docs/spec.mdanddocs/api.mdare synced with the Worker's copies.Needs a Worker that has the roles; the change is additive on the wire.
Test plan
cargo fmt --checkcargo clippy --workspace --all-targets -- -D warningscargo test --workspace(includes new model tests for the roles)Generated by Claude Code