Disclaimer
- This is a PROPOSAL, not an announcement. This topic is a work in progress. We encourage you to do join this work in a constructive way.
- The top post may be updated. If you comment on something specific - quote the text you are commenting.
This is a proposal for a new Community Initiative.
GitOps for Fedora Packagers
Overview
The goal of the initiative is to explore the possibility to use a Git Forge interface as a main driver for packaging tasks in Fedora. We will demonstrate the potential of this approach and gather packager feedback.
There are number of processes in the Fedora project which are traditionally implemented via different custom tools, for example:
- Add a new package to the distribution → Bugzilla ticket for a Review Request
- Notification of new upstream version → Bugzilla ticket
- Create a new build → koji build
- Add a new build to a buildroot → Bodhi update
- Add a new build to a compose → Jenkins pipeline
If we implement each of those actions as pull requests in a Git Forge to a certain Git repository, we reduce the number of custom tools we maintain in the project and amount of onboarding a newcomer needs to start contributing.
Phase 1: Represent a Bodhi update as a Pull request to a Git repository
Idea
As a first exploratory step we propose to focus on a specific action in the Fedora Packager workflow: a bodhi update.
In this phase there will be no changes to the current workflow. Rather the goal is to create a mirror of the existing process.
- We create a Git repository which represents a distribution. A branch in the repository is roughly equivalent to a target Koji tag of a Bodhi update.
- For each new Bodhi update we create a Pull Request to the repository.
- For each gating test, karma vote and comment we add CI vote and comment on that Pull Request
- As soon as Bodhi update passes the gate the Pull Request will be merged.
- [bonus] Each compose can be represented as a git tag on the commit, which represents the state of the koji tag which was used to build that compose.
Why
This first phase will allow us to iterate on the format of the pull request and the repository content using the real-world examples from the active Fedora packaging process. If, after a period of testing, we are satisfied with the implementation, we will be able to go to a phase two to completely replace Bodhi with the Git Forge-driven workflow.
While the first phase will not change anything in the existing workflow, it will already add visibility to the current state of the distribution:
- a Git Forge user can watch the state of a pull request and get notifications about it
- a Git user can compare the states of the distribution and easily get a diff between the branches or list of changes landing into a distribution in a last week.
- downstream consumers of Fedora packages will be able to setup their own actions on the changes in the state of the repository.
This is technically doable with the existing infrastructure tooling, but it will become possible to do this using a standard Git Forge interface alone, without any knowledge of custom Fedora services, tool and concepts like Koji Event ID.
How
We need to run a service able to react to Fedora Messaging events and access the Git Forge APIs.
For that we need:
Design:
- We need help from people with bodhi expertise to review the design and to support the work as SMEs.
- We would benefit from the expertise of Packit team on dealing with Git Forge APIs.
Development:
- We need to develop the core logic of the service: transform Fedora Messaging event into an action on GitForge.
- We need to create deployment scripts for the service (Ansible playbooks, Helm charts,.., depending on the existing expertise and interest)
Ops:
- Someone from CLE to help with deploying and running the service for at least a year.
Hardware and other resources:
- We need a workspace at one of the Git Forges for the main repo. Most likely Codeberg (until we have our own Forgejo deployment)
- We need a place to run a service - most likely a tenant at the one of the Openshift clusters
- Any standard infrastructure to host the service and run deployment scripts (some GitForge + CI)
- As the service will be a mostly stateless microservice translating one json into another, there is no need to discuss hardware requirements.
Communication and feedback loop:
- Support for presenting the work at Flock and other relevant places and collecting feedback
Timeline
The rough possible timeline for the phase 1 is:
- Apr 1, 2025 - Get the approval for the initiative
- Apr 10, 2025 - Get the people and access to the infrastructure resources for them
- May 1, 2025 - Run the initial implementation of the service reading Bodhi messages
- June 1, 2025 - Implement Open PR/Merge PR functionality by Flock
- July 1, 2025 - Add the Update the PR with karma votes and comments and CI results
- August 1, 2025 - Add tags for some of the composes.
- August 15, 2025 - Announce the work on Fedora Magazine and start the feedback gathering
- February, FOSDEM 2026 - Collect feedback, present the result, and propose next steps at CentOS Connect or Distribution Devroom.
Please share you feedback in the comments below.
If you want to work on this project - reach out to @bookwar:fedora.im at the Fedora Council channel on Matrix.