Access and roles
Roles
| Role | Can |
|---|---|
| viewer | Read, sync, see locks and history |
| contributor | Also lock, submit, shelve, open merge requests |
| maintainer | Also merge, break locks, manage runners and secrets |
| admin | Also change access, protection and repo settings |
Server admins (LODEBASE_ADMINS, LODEBASE_ADMIN_GROUPS) are admins on every repo. In an org, org owners are admins on its repos, and members get the org's member role (orgs).
Granting access to a repo
Principals are * (everyone signed in), user:<name> and group:<group> (a group from your sign-in provider's groups claim).
sh
lode access # your role, groups and the path rules that apply to you
lode access grant '*' viewer
lode access grant group:artists contributor
lode access members
lode access set-rules rules.txtPath rules
Path rules narrow what a role allows, per folder. One rule per line, last match wins:
# outsourcers stay out of code
deny group:outsourcers write,lock Source/**
allow user:sam write Source/Tools/**write covers submitting; lock covers taking locks. Path rules restrict; path owners add review on top.
Server settings for access
| Variable | Default | Meaning |
|---|---|---|
LODEBASE_ADMINS | (none) | Users (name or subject) who administer every repo |
LODEBASE_ADMIN_GROUPS | (none) | Groups whose members administer every repo |
LODEBASE_REPO_CREATION | everyone | Who may create repos and orgs: everyone or admins |
LODEBASE_DEFAULT_ROLE | contributor | Role * gets on new personal repos (none makes them private) |
LODEBASE_LOCK_STALE_HOURS | 72 | Locks from workspaces silent this long are marked stale |
Make sure your OIDC provider puts a groups claim in the token (authentik's profile scope does by default).