I've been coding up a new project to do the infragit push hook with fedora-messaging (i.e., to replace the fedmsgs that currently get published when someone runs a git push to our Ansible project).
This project doesn't just port that hook to fedora-messaging, but it also defines a message schema for those messages, so the schema can be enforced both on publishing and on receiving. The schema are also a nice way for Python consumers to interact with the messages that allows them to avoid messing with JSON or raw dictionaries.
One thing I've been considering is whether this project should be more general, because I've noticed that we have what looks like copied code in our Ansible repo in other places for other git hooks to publish fedmsgs. The copied code is not an exact copy, but it's clear that one was copied from the other and then altered. We could use this as an opportunity to share code in the same repo, or we could make three repos (one that has the shared code, and two for the specific use cases that subclass the shared code).
I think we could probably get both use cases into the same repo, but I could work with three as well if we want. However, thinking about this now is good, because how we name the project should reflect which choice we make. I've currently named what I have fedora-messaging-infragit, which is not for the general case.
So, what do we want to do and what should we name it?
No rush, I can work on my laptop until we have a name and a place to put it.
You can create it yourself on https://github.com/fedora-infra (New green button on the right).
@kevin enabled that permission couple days ago, I am not sure if we want to keep it that way or not but for the time being you can self serve yourself :smile:
Metadata Update from @cverna:
- Issue close_status updated to: Fixed
- Issue status updated to: Closed (was: Open)
OK, thanks for the info. I think in that case that I will just make a repo that is specific to just the infragit repo and push that up. When we later decide to work on the other git push hook, we can decide then whether to combine the code, or whatever else. This way I can proceed with packaging this one and getting the port done.
to comment on this ticket.