Forgejo Integration
Connect a repository on Codeberg or another Forgejo instance with an access token. FirmwareCI sets up the repository’s webhook itself.
Prerequisites
- Repository set up with
.firmwareciinfrastructure (see Repository Setup) fwciCLI tool, up to date and authenticated- Admin rights on the repository
Setup Steps
1. Create an Access Token
In Forgejo, open Settings > Applications of your account and generate a token with the write:repository
scope. FirmwareCI reads the configuration with it, sets the webhook and reports on commits. fwci integration
refuses a token that can’t set the webhook, such as one with only read:repository, before the project exists.
2. Link the Repository
On your own instance, use its host, with -P <port> for another port than 443 and -H for plain HTTP. fwci
recognises Forgejo by its version endpoint. The webhook gets a secret of its own for this project.
To change the token, run the command again with -u. That also gives the webhook a new secret.
3. Verify Integration
Push a commit. Its Firmware CI Synchronization status turns from pending to success, or to failure with what failed.
How It Works
Automatic Configuration Updates:
- Branch and tag pushes: Update that branch’s or tag’s configuration on FirmwareCI, see the Branches reference.
- Deleting a branch or tag: Removes it from FirmwareCI; its jobs and history remain reachable.
- Late pushes: Only the newest commit of a branch syncs. An older push that arrives late gets the warning
Not synchronized: superseded by <commit>.
Status Reporting:
- The sync’s result is the commit status Firmware CI Synchronization. Forgejo shows only the start of a status, so FirmwareCI also writes the whole report as the commit’s git note, which Forgejo shows on the commit page. The status’s Details link leads there. The note replaces one that was already on that commit.
- Each test of a job request from Forgejo Actions is a commit status named after the test, linking its job: pending while it waits and runs, then success, failure, or error when it was aborted.
- FirmwareCI uses the token only for this repository’s instance. A pipeline sends none.