Travis-CI is a crucial component in Continuous Integration/Continuous Deployment. We use it a lot to run unit tests and building/uploading Python modules.
Recently I had to solve a problem of building RPMs on Travis-CI with Docker containers. In this post I will describe step-by-step how to do that.
We distribute our backup tool as RPM packages for CentOS 6 and 7. But Travis-CI slaves run Ubuntu trusty. In theory I could use a tool like fpm and build RPMs on Ubuntu (never tried that, but should be possible). However I like to have a .spec file. It gives you full flexibility on how RPM behaves and it’s easier to maintain it.
Travis-CI supports Docker containers, so I decided to go that way.
At high level the process is following. A Travis-CI slave starts a docker daemon. A …[Read more]