gems
Ruby Gem Polisher Update
Submitted by mmorsi on Wed, 2010-04-14 06:27
Alot of changes have gone into Polisher since my last update (eg the initial release). Most notably, the focus of Polisher has been changed and expanded, it now serves as a generic upstream project post-release processing tool, which can be used to configure any number of upstream projects w/ many various sources, and associate events with them to be triggered on releases. Polisher still works w/ the gemcutter API (namely the subscriptions / webhooks) as well as with gem2rpm, but now they are special cases in the generic upstream project management framework.
In the backend, Polisher is now based on Sinatra, which is far more lightweight and flexible than the previous solution, Rails. Rails is a powerful framework in itself, but I was looking for something small to help me establish the primary REST interface to the webapp.
Polisher also provides a nice DSL interface which can be used to define and run mass project / source registrations and trigger events in order to automate many various releases at the same time. I went through and picked several popular ruby-related packages from the current Fedora Repos, and wrote Polisher scripts for all of them, establishing several yum repositories for various Ruby related stacks.
Currently I have setup:
* stable - same packages that are currently in Fedora updates
* maintenance - later releases in the same major version branch of the packages currently in stable
* devel - packages that work w/ Ruby 1.9 (great resource)
* rawhide - all latest project versions
By tweaking the Polisher scripts and rpm spec file templates, the contents of these repos can be changed and new ones can be setup for any target software stack.
Any Fedora / yum user can simply point a yum repo entry towards any of those before running a yum update to get all the latest Ruby packages provided by that repo. Warning no functionality is guaranteed, there may currently be major breakage as Polisher and the scripts themselves are a work in progress. Furthermore, I'm in the process of setting up various Fedora based appliances, each pointing at a different Polisher generated repo by default. Any user can easily startup a VM on their local machine based off any of those appliances and instantly have Fedora w/ a complete Ruby stack for whichever version of Ruby they want to use. It's a work in progress, and I will have a link up soon to the downloadable images.
It would be awesome to get some help from anyone in the community that's interested in Ruby on Fedora (or any upstream project post-release processing on any flavor of Linux in general, as it's trivial to expand Polisher to handle any input/output package or repository format). It is a bit of effort to get Polisher scripts written for every Ruby related package, but if this thing starts rolling, I can see this as being a useful tool in the "upstream project to Fedora repo" process as mass parallel source releases can be triggered and handled easily in a committable / reproducible / reliable fashion.
Well that's it for now, be sure to note the many updates to deltacloud and many to my own projects, more on all of those in the near future.
Until next time, take it easy.
ruby gem polisher
Submitted by mmorsi on Thu, 2010-01-14 18:28For anyone that missed it Pavol Rusnak had an excellent blog post on Fedora Planet regarding the current state of rubygems, specifically with gemcutter becoming the official rubygems source and the introduction of the new gemcutter webhook API to register callbacks to be invoked on gem updates. Also discussed is gem2rpm, which automatically converts a gem to a rpm specfile / srpm, and the need of a tool to bind those two components together.
Introducing Polisher which does just that, a rails based webapp that allows a user to add any number of gem sources, customize the packages they want to track, and register handlers to be invoked on certain gem events. Currently I have handlers to simply send an email, and/or generate a rpm artifact from the gem, and the interface is extensible enough so that anyone can add any event handler easily. I am currently working on a module that will automatically submit a bugzilla request for the gem/rpm. This will entail a feature akin to the 'dirty bit' discussed in Pavol's blogpost, for packages that need extra maintenance before submission, but polisher will still assist in the process in any case (and its possible we can develop a maintenance automation system which runs a maintainer's scripts to make changes to the package before bugzilla submission).
It is still early in development, the current state is the result of only a few days of coding, but I think it's already useful for the Ruby -> Fedora process. Lots of things still need to be added, there is no-multiuser support currently for example, but I'm already able to register callbacks for gemcutter gems, which upon being updated, get invoked.
Polisher is a webapp since the gemcutter webhook API takes a http url which to invoke w/ POST params on a gem update. Whoever will want to run this will need a public-facing domain to do so. I put a copy up on my personal domain, feel free to give it a try, just please don't try to stress test it ;-) (and forgive the simplistic interface, was going for functional/quick). polisher demo
At some point, if this takes off, it would be awesome to get some hosting space for the Fedora community, and to setup an automated Ruby->Fedora workflow engine, w/ maintainer intervention at the appropriate points.
The polisher source is licensed under the GPL and can be downloaded from github. I also pushed the polisher gem to the gemcutter repo and you can install it w/ gem install polisher provided you have a recent enough version of rubygems (w/ gemcutter officially part of the repo list).
Speaking of rubygems I've also pushed gems for several of my other projects including rxsd, simrpc, and motel, all of which are now available via gem install. Enjoy!



