Perkins
A travis compatible minimal CI solution built in ruby
Behind the scenes perkins uses a slightly modified version of travis-build library and uses Travis-yaml gem to parse the .travis.yml files on existing repos. Also it integrates the Log.js library to display the build log the same way Travis does.
Said that, big kudos to Travis team for open sourcing those components and save us months of work.
Why not use Travis open source app ?
Travis code is undoubtedly a piece of art, but at the same time is a complex application, made of several components, at least 8, with a service-oriented architecture. That's great! but for personal use or for a small teams it's difficult to manage many applications for a single task, so we prefer to use a monolithic, lightweight solution to run our specs, in a Travis compatible way, yay!
Status:
Perkins is at experimental fase, use at your own risk.
Features:
- Github webhook receiver.
- Github status sender from builds.
- Github repo selector from user & organizations.
- .travis.yml detection.
- Concurrent builds.
- Build support for ruby (supports bundler and rvm or chruby).
- Build support for Go.
- Addition of more languages should be trivial thanks to travis-build.
- Badge generation through https://img.shields.io/ service.
Installation
gem install perkins
Usage
perkins server config.rb --port=3000
or
bundle exec perkins server config.rb --port=3000
Configuration
configuration file for perkins to run.
Perkins.application do |app|
config do |c|
c.sse_endpoint = ENV['ENDPOINT']
c.port = ENV['PORT']
c.redis = {host: "localhost"}
c.database = File.("../path/to/database.yml", __FILE__)
c.github_client_id = ENV['GITHUB_CLIENT_ID']
c.github_client_secret = ENV['GITHUB_SECRET']
end
end
Config oauth app in github
https://github.com/settings/applications
Webhooks
To set the webhook for a repo you can go to github repo admin or visit a perkins repo on youapp.com/repos/my/repo/config
Travis.yml
When Perkins runs a build it will search for a travis.yml file on the root of your repository, so existing repos with that file will just work.
You can read more info about build config at: http://docs.travis-ci.com/user/build-configuration/
Contributing
- Fork it ( https://github.com/michelson/perkins/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request