2 July presentation
Anthony Wang edited this page 2022-07-24 03:56:36 +08:00
title author date theme
Gitea Federation Development Anthony Wang 2022-07-20 Berlin

You can find a recording of the presentation here.

Current progress

Gitea main

  • Not much currently, but the building blocks are there.
    • User keypairs and HTTP signatures

Pull request #20391

Steps to implement a federated feature

Step 1

  • Think about and conceptually design the feature.
  • Example: We can support account migrations using a Move activity like what Mastodon does, and we'll need a UI to migrate all of an account's repos.

Step 2

  • If there are spec-level changes, contribute them to ForgeFed.
  • Example: Submit a PR to ForgeFed documenting the usage of Move.

Step 3

  • Implement the feature in Gitea.
  • Example: Write backend code for sending/processing Move and implement the UI.

Upcoming challenges

Frontend/UI

  • I'm temporarily using some Ruby scripts and handwriting AS objects, but that won't work long-term.
  • I predict this will be tricky and time-consuming, so we should start now.
  • Reuse current Gitea UI but add federation handling to internal functions?
    • Example: Use current create new issue UI, but handle federated issues in issues.CreateCommentCtx().

Federated collaborators and organizations

  • Federated collaborators:
    • How to handle Git push?
    • How to handle settings synchronization?
  • Federated organizations:
    • A huge headache due to all sorts of crazy scenarios that can happen.
    • Example: User on instance A is in a organization on instance B and forks a repo located on instance C to the organization.

Permissions and private repo federation

  • fr33domlover is working on OCAP in ForgeFed.
  • Another simple solution is to use HTTP signatures for authentication.
    • Example: I would like to view open issues on a remote private repo, so my instance uses my private key to send a signed request to the remote instance's Ticket actor endpoint.

Contributors

  • I won't have much time over the next two weeks to work on Gitea.
  • Both Loïc and I posted calls for help on the fediverse, but no one has showed up yet.
  • Contributions to my Ta180m/gitea fork highly welcome!
  • Gergely Nagy set up daily Docker builds of my Gitea fork, so it'll be easy for testers to try it out.

Moderation

  • Blocking instances
    • Add each remote instance as a login source, then you can disable login sources in the admin UI?
  • Blocking users
    • Any ideas how to do this?