Deadline October 1st, 2021 https://nlnet.nl/thema/NGIZeroDiscovery.html https://nlnet.nl/propose/ Thematic call: https://nlnet.nl/thema/NGIZeroDiscovery.html Your name: Andrew Thornton Email address: art27@cantab.net Phone numbers: [redacted] Organisation (if any): Country: United-Kingdom > Project name: Federated software forges with Gitea > Website / wiki: https://en.wikipedia.org/wiki/Gitea > Abstract: Can you explain the whole project and its expected outcome(s). Gitea is a popular software forge (over [100 millions downloads on the docker hub](https://hub.docker.com/r/gitea/gitea/)) that allows [searching the content of code repositories](https://docs.gitea.io/en-us/repo-indexer/). It is however not possible to run a search on multiple Gitea instances, it must be repeated on each of them. The **goal of this project is to implement federation features in the Gitea codebase**. It is an enabler that can be used to implement a distributed search. An individual or an organization can run its own Gitea instance and migrate projects to and from other Gitea instances. It is a decentralized service that provides data portability. Once a project is fully migrated from one instance to another, all developers must resume their work on the new instance. A new communication channel based on the **W3C ActivityPub** protocol is implemented to allow them to communicate with each other. Activities carried out on one Gitea instance are sent to the other instances at all times. The [go-fed](https://github.com/go-fed/activity) library implementing the ActivityPub protocol will be improved to match the quality standards required for Gitea releases. > Have you been involved with projects or organisations relevant to this project before? And if so, can you tell us a bit about your contributions? Andrew is the [most active Gitea contributor in recent years](https://github.com/go-gitea/gitea/graphs/contributors?from=2018-09-20&to=2021-08-04&type=c) contributing to all parts of Gitea. Aware of the problems of centralised forges from the days when Sourceforge was the most popular forge, he became involved with Gitea because it presented a lightweight alternative for self-hosted forges. Matti is an elected project owner of Gitea serving [three consecutive terms](https://github.com/go-gitea/gitea/blob/main/CONTRIBUTING.md#owners). He became involved with Gitea as a way to create a home for his open source work that wasn't beholden to existing walled gardens, and stayed to help build a platform for other developers to use to create their open source software. > Requested Amount: 50,000€ > Explain what the requested budget will be used for? Does the project have other funding sources, both past and present? (If you want, you can in addition attach a budget at the bottom of the form) Gitea is supported by sponsors that provide "in kind" resources such as hardware or hosting. Financial donations amount to a total of ~20,000€ since the beginning of the project and has not been used to advance the development of the project. Gitea developers are not paid by the Gitea project, their contribution is on a volunteer basis. The discussions regarding the support of ActivityPub in Gitea started late 2020 (https://github.com/go-gitea/gitea/issues/14186) but the developers involved in Gitea did not have the resources to make progress. In August 2021 a 5,000€ grant from https://fedeproxy.eu earmarked to further federation in Gitea created an incentive to start with the implementation of a few essential work items (https://github.com/go-gitea/gitea/labels/theme%2Ffederation#). The bulk of the work will however require significantly more funding. The budget will be used exclusively to pay for the time of Andrew Thornton and Matti (480€ per day). The outcome of their work will be as follows: * An **implementation of the essentials of the ActivityPub protocol** is released in Gitea based on the go-fed library; * An **improved version of the ActivityPub test suite** included in the CI to publish versions of Gitea that are production ready. * The **Gitea internals are modified to facilitate the implementation of ActivityPub** and the integration of the go-fed library; * **Reports explaining the data model and vocabulary used by Gitea** are communicated to forgefed with a request for comment; * A **monthly report is published in the Gitea project pages** summarizing the work done since the last report; * A **monthly videoconference is held in public and recorded** to discuss the monthly report; * **5% of the time is dedicated to improving diversity** in the Gitea project Please find the development plan attached. > Compare your own project with existing or historical efforts. Regarding federation, a [forgefed plugin](https://pagure.io/pagure-forgefed) was developped for the [pagure](https://pagure.io) forge in 2021. There are discussions related to federation in GitLab but there is no ongoing development. The vervis forge initiated by the authors of forgefed is no longer actively developped. Gitea is arguably the most popular Free Software forge behind GitLab. * Top 500 project on GitHub with 25,000 stars * [100 millions+ downloads on the Docker hub](https://hub.docker.com/r/gitea/gitea/) * Available on cloud providers such as [AWS](https://aws.amazon.com/marketplace/search/results?searchTerms=gitea), [DigitalOcean](https://marketplace.digitalocean.com/apps/gitea), [Cloudron](https://docs.cloudron.io/apps/gitea/) or [ScaleWay](https://www.scaleway.com/en/docs/configure-gitea-code-hosting-solution/) etc. * Natively [supported by competitors such as GitLab](https://docs.gitlab.com/ce/user/project/import/gitea.html#import-your-gitea-repositories). * Used by well known projects and organizations such as [OpenStack](https://opendev.org/), [PostGIS](https://git.osgeo.org/gitea/postgis/postgis), [Codeberg](https://codeberg.org/) etc. * Natively [packaged in distributions](https://www.wikidata.org/wiki/Q28714270) such as Snap, NetBSD, Gentoo, etc. * Integrated in well known SDKs such as [Visual Studio](https://marketplace.visualstudio.com/items?itemName=MysticBoy.GiteaExtensionforVisualStudio), [JetBrains](https://www.jetbrains.com/help/youtrack/standalone/integration-with-gitea.html), [redmine](https://github.com/tf/redmine_merge_request_links#gitea), [etc.](https://gitea.com/gitea/awesome-gitea/#sdk). There is no project to provide a distributed search that would return results aggregated from multiple self-hosted forge instances. > What are significant technical challenges you expect to solve during the project, if any? Gitea adopting **federation will require a little bit of a different philosophical mindset** than perhaps is common. Rectifying that, or isolating that, with the existing codebase is a core engineering challenge. For instance, the security model needs to be revised to take into account incoming messages from other Gitea instances. It no longer is just about moderating users with a registered and active account. ActivityPub is a recent standard of the W3C, last published in 2017, and has not reference implementation in Go, the langage used by Gitea. **The ([go-fed](https://go-fed.org/)) library developed since 2019 is a good starting point but is still in its infancy** and requires work before it is production ready. In addition, the data models specific to the Software Forges domain ([forgefed](https://forgefed.peers.community/)) are still in the draft stage: only part of them can be used. > Describe the ecosystem of the project, and how you will engage with relevant actors and promote the outcomes? Gitea is a community driven project and has no centralized authority. Although people are [appointed by vote](https://github.com/go-gitea/gitea/blob/main/CONTRIBUTING.md#maintainers) and have a leadership position, the [roadmap is largely self-organized](https://github.com/go-gitea/gitea/issues/16429). **Implementing federation in Gitea is therefore less of a one time decision and more of a continuous dialog with the community of developers. As a result, the roadmap is likely to be challenged in ways that are difficult to forsee.** The go-fed library author originally reached out to Gitea and authored the first version of the development plan to implement ActivityPub. He welcomes improvements to the library and the ActivityPub test server. The availability of federated features in Gitea will be announced with each new Gitea release. > What should we do in the other case, e.g. when your project is not immediately selected? X I want NLnet Foundation to erase all information should my project proposal not be granted