Kestrel

Docs / Access & audit

Access & audit

Give every person and every pipeline the narrowest access that still lets it work — and record everything that happens.

Roles

Roles are granted per namespace or per repository. A grant on a namespace applies to all repositories inside it unless a repository overrides it.

RolePullPushDelete / retentionManage access
ViewerYesNoNoNo
PublisherYesYesNoNo
MaintainerYesYesYesNo
OwnerYesYesYesYes

Tokens

A token is a credential with explicit scopes, optionally limited to named repositories. Pipelines should use tokens, not personal credentials. A token can be revoked at any time; revocation applies to the next request.

# Create a write token limited to one repository
kestrel token create --name ci-api-gateway \
  --scope pull,push \
  --repository platform/api-gateway

# List tokens and revoke one
kestrel token list
kestrel token revoke --name ci-api-gateway

Clients pass the token in the KESTREL_TOKEN environment variable, as shown in the quickstart.

Audit log

The audit log is append-only. Each entry records the actor (person or token), the action, the target, and the artifact digest when one is involved. Typical entries:

- actor: token/ci-api-gateway
  action: artifact.push
  repository: platform/api-gateway
  tag: 1.4.2
  digest: sha256:9c1f4a2e7b8d0c35f6a19e2d4b7c8091a3e5f2d6c8b0a4e7f1d2c3b4a5960718

- actor: user/mara
  action: retention.apply
  repository: platform/api-gateway
  removed: 7

- actor: user/odin
  action: token.revoke
  token: ci-old-runner
Design rule: if an action changes what others can pull or trust, it belongs in the audit log. Reads are counted for capacity planning but are not part of the compliance trail.