Home Getting started

Roles & permissions (RBAC)

izihub uses layered access control: site admins, organizations, teams with unit permissions, repository collaborators, and branch protection.

1. Site

Instance admins manage users, auth, and system settings.

2. Organization

Teams map to roles. Default org is private.

3. Repository

Collaborators for one-off access; teams for ongoing work.

4. Branches

Protect main so only reviews/merges land there.

Standard organization roles

Role Code Issues PRs Releases Wiki Projects Packages Actions Create repos
OwnersAdminAdminAdminAdminAdminAdminAdminAdminYes
Org-AdminsAdminAdminAdminAdminAdminAdminAdminAdminYes
MaintainersWriteWriteWriteWriteWriteWriteWriteWriteYes
DevelopersWriteWriteWriteReadWriteWriteReadReadNo
ReviewersReadWriteWriteReadReadReadReadReadNo
ReportersNoneWriteNoneNoneNoneReadNoneNoneNo
ReadersReadReadReadReadReadReadReadReadNo
CI-BotsReadReadReadWriteNoneNoneWriteWriteNo

Who should get which role?

How to set it up

  1. Create the admin — register the first account on the web UI, or run
    ./scripts/rbac-bootstrap.sh --create-admin --admin-user iziadmin --admin-email you@example.com
  2. Bootstrap teams — with an admin token:
    ./scripts/rbac-bootstrap.sh --token YOUR_TOKEN --url http://YOUR_HOST:3000
    Creates the private izihub org and all standard teams.
  3. Add people to teams — Organization → Teams → add members, or
    ./scripts/rbac-bootstrap.sh --token … --assign alice Developers
  4. Protect main — each repo → Settings → Branches → protect main (require PR, block force-push).
  5. Harden registration — for a private forge set DISABLE_REGISTRATION=true in .env and recreate the server.

Repository collaborators (personal / exceptions)

For a single repo outside the org model:

Prefer org teams for anything ongoing so access is reviewable in one place.

Real enforcement (active)

Branch protection is applied automatically to org repositories:

Policy file: rbac/enforcement.json · re-apply: ./scripts/enforce-protection.sh

A timer re-applies rules every 2 minutes so new repos are protected without manual steps.

Demo: org repo protected-demo — try pushing to main to see rejection.

Site roles