Ruby on Rails 的持续集成?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/220668/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Continuous Integration for Ruby on Rails?
提问by Jim Fiorato
I've been searching around for a Continuous Integration solution for Ruby on Rails, but haven't been too pleased with the results. I came from a .NET shop that used CruiseControl.NET and was really spoiled with its ease of use and rich status/reporting.
我一直在寻找 Ruby on Rails 的持续集成解决方案,但对结果不太满意。我来自一家使用 CruiseControl.NET 的 .NET 商店,它的易用性和丰富的状态/报告真的被宠坏了。
Ideally I'm looking for:
理想情况下,我正在寻找:
The obvious Git/SVN and Test::Unit integration
Integration with Rake and/or Capistrano
A web interface showing the status of the build
Email notification of failed builds.
Desktop notification (potentially through Growl)
REST API for build statuses
Plugin framework for running other code analysis tools and reporting results in the UI
明显的 Git/SVN 和 Test::Unit 集成
与 Rake 和/或 Capistrano 集成
显示构建状态的 Web 界面
失败构建的电子邮件通知。
桌面通知(可能通过 Growl)
用于构建状态的 REST API
用于运行其他代码分析工具并在 UI 中报告结果的插件框架
采纳答案by TALlama
I just went through the options here and thought I'd roll them up as of late 2011.
我刚刚浏览了这里的选项,并认为我会在 2011 年末将它们汇总起来。
Integrity
正直
After a near-death experiencethat left the still-linked-to websitewith outdated informationand downed the demo site, this project has a spark of life again. But the documentation hasn't moved on, and lots and lots of the steps in the tutorial are just plain broken; I had to change references to gems, build some things out of band, and then I still couldn't get it working.
在濒临死亡的经历使仍然链接到的网站上的信息过时并关闭演示网站后,该项目再次焕发了生机。但是文档并没有继续前进,并且教程中的很多步骤都被破坏了;我不得不更改对 gem 的引用,构建一些带外的东西,然后我仍然无法让它工作。
Cruise Control.rb
巡航控制.rb
Dead simple: you just download it, run a command line to add your project (there is no UIfor doing so), and run the Rails app. But there's no UI for editing your project, either, and there's no real integration with build artifactsaside from displaying links to them: you get no graphs of tests run, no trend lines, etc. I also had to adjust the routes.rbfile to get the code linking working (the resources :projectsline needs to move below all the other non-default routes).
非常简单:您只需下载它,运行命令行来添加您的项目(没有这样做的UI),然后运行 Rails 应用程序。但是也没有用于编辑项目的 UI,并且除了显示指向它们的链接之外,也没有与构建工件的真正集成:您没有运行测试图,没有趋势线等。我还必须调整routes.rb文件以获得代码链接工作(该resources :projects行需要移动到所有其他非默认路由下方)。
TeamCity
团队城市
This looks awesome, but the pay scale seems out of whack. 3 agents free and then when you're dependent you need to dole out hundreds of dollars. Personal Buildslooks great, but don't have the budget.
这看起来很棒,但薪级表似乎不正常。3 个代理免费,然后当您依赖时,您需要支付数百美元。Personal Builds看起来不错,但没有预算。
Jenkins(née Hudson)
詹金斯(姓哈德森)
This is a Java stalwart and it is loaded up with a thousand options, so the UI is confusingand it's a chore to set up your projects. But once you set it up you get a whole lot of pluginsthat can pull from most anywhere, run most anything, and report most everything. The OS X Installer points Jenkins at /Users/Shared/Jenkins/Homebut fails to create that directory or chownit to daemon(which is uses by default, and you should change to a new jenkinsuser so you can set up GitHub integration).
这是一个 Java 中坚力量,它装载了上千个选项,因此UI 令人困惑,并且设置您的项目是一件苦差事。但是一旦你设置好了,你就会得到一大堆插件,它们可以从大多数地方提取,运行大多数东西,并报告大多数东西。OS X 安装程序将 Jenkins 指向/Users/Shared/Jenkins/Home但未能创建该目录或chown它daemon(默认情况下使用,您应该更改为新jenkins用户,以便您可以设置 GitHub 集成)。
Others
其他
I didn't really try these, but thought I'd mention why:
我没有真正尝试过这些,但我想我会提到原因:
- CI Joewants to own the GitHub repo more than I want it, and its creators aren't even using it; they're on Jenkins.
- Cerberusseems neatly small but doesn't have a UI and doesn't automatically publish build artifacts where others can see them.
- BigTunaseems to be a CruiseControl.rb clone without the (already minimal) community support.
- Bamboolooks really neat if you use JIRA and BitBucket, but we use neither. It does deploys but we already have those set up in Capistrano.
- CI Joe比我想要的更想拥有 GitHub 存储库,而它的创建者甚至没有使用它;他们在詹金斯。
- Cerberus看起来非常小,但没有 UI,也不会自动发布构建工件,让其他人可以看到它们。
- BigTuna似乎是 CruiseControl.rb 的克隆,没有(已经很少)社区支持。
- 如果您使用 JIRA 和 BitBucket,Bamboo看起来非常整洁,但我们都不使用。它确实部署了,但我们已经在 Capistrano 中设置了这些。
The Choice
选择
We went with Jenkins, but I really wish one of the lighter-weight solutions had worked out.
我们选择了Jenkins,但我真的希望其中一种更轻量级的解决方案已经成功。
回答by craigb
How about CruiseControl.rb?
CruiseControl.rb怎么样?
Same crowd that did CruiseControl(thoughtworks) and written in Ruby. Very easy to use Raketo integrate your other tools, and can use the ruby-growlgem for your notifications.
相同的人群CruiseControl(思想作品)并用Ruby. 非常容易用于Rake集成您的其他工具,并且可以使用ruby-growlgem 来发送通知。
回答by Julian
You might also want to consider Hudson. It is designed for use with Java projects although there is a great selection of plug-ins available including support for Ruby and Rake. It has a very useful web interface and supports email notifications as well as many others (like twitter, or giant bear lamps).
您可能还想考虑Hudson。它专为与 Java 项目一起使用而设计,尽管有很多可用的插件可供选择,包括对 Ruby 和 Rake 的支持。它有一个非常有用的 Web 界面,并支持电子邮件通知以及许多其他功能(如 twitter 或巨型熊灯)。
The community is also very active and there have been several articleson hooking up Hudson with Selenium which you might be helpful for testing Rails applications on the browser side.
社区也非常活跃,已经有几篇关于将 Hudson 与 Selenium 连接起来的文章,您可能会对在浏览器端测试 Rails 应用程序有所帮助。
Another one look at is Team Citywhich is free for small projects and teams (including commercial). I really like Team City and have used it before for other projects but currently we're using Mercurial for source control and Team City's support was a little too beta when we were considering it.
另一种是Team City,它对小型项目和团队(包括商业)免费。我真的很喜欢 Team City 并且之前在其他项目中使用过它,但目前我们正在使用 Mercurial 进行源代码控制,当我们考虑它时,Team City 的支持有点太测试版了。
I switched from CruiseControl.net to Team City and was absolutely shocked at the improvement. I'm partial to Hudson though because of its similar feature set and very active community.
我从 CruiseControl.net 切换到 Team City,对改进感到非常震惊。我偏爱 Hudson,因为它具有相似的功能集和非常活跃的社区。
回答by Paul Biggar
Circleis an advanced CI service for Rails(and other web apps). From your list, it supports the following:
Circle是Rails(和其他 Web 应用程序)的高级 CI 服务。从您的列表中,它支持以下内容:
- Git and Test::Unit integration(also RSpec, Cucumber, Jasmine, Konacha integrations, and supports arbitrary extra test commands)
- Integration with Rake and/or Capistrano(uses Rake to run commands and set up DBs, support continuous deployment using Capistrano or Heroku, or anything really)
- A web interface showing the status of the build
- Email notification of failed builds.
- Desktop notification(through CCMenu/CCTray)
- REST API for build statuses
- Plugin framework for running other code analysis tools and reporting results in the UI(we can run arbitrary commands and support including their status as part of the build)
- Git 和 Test::Unit 集成(还有 RSpec、Cucumber、Jasmine、Konacha 集成,并支持任意额外的测试命令)
- 与 Rake 和/或 Capistrano 集成(使用 Rake 运行命令和设置数据库,支持使用 Capistrano 或 Heroku 或任何真正的持续部署)
- 显示构建状态的 Web 界面
- 失败构建的电子邮件通知。
- 桌面通知(通过 CCMenu/CCTray)
- 用于构建状态的 REST API
- 用于运行其他代码分析工具并在 UI 中报告结果的插件框架(我们可以运行任意命令并支持将它们的状态作为构建的一部分)
Joel and I spent a while chatting about this on the Stackoverflow podcast- check it out!
Joel 和我在Stackoverflow 播客上讨论了一段时间-看看吧!
(edit) Disclaimer: Paul Biggar founded Circle as he states in his Stackoverflow profile
(编辑)免责声明:Paul Biggar 创立了 Circle,正如他在 Stackoverflow 个人资料中所述
回答by Joshua Pinter
Updated Feb-2015
2015 年 2 月更新
Codeship
代号
There was a lack of development on Drone.io so I switched to Codeship and I'm thoroughly enjoying it. It's actively developed and improved, has great design and is very fast. Plus, for the bottom tier it's actually free (up to 100 builds per month) so it ended up being cheaper than Drone.io.
Drone.io 缺乏开发,所以我切换到 Codeship,我非常享受它。它得到了积极的开发和改进,具有出色的设计并且速度非常快。另外,对于底层来说,它实际上是免费的(每月最多 100 次构建),因此它最终比 Drone.io 便宜。
Original Answer
原答案
Drone.io
无人机网
I just setup our main Ruby on Rails application with http://drone.io/. Was a piece of cake and it's got a great interface. I'd say worth checking out if you're looking for a simple, hosted solution.
我只是使用http://drone.io/设置了我们的主要 Ruby on Rails 应用程序。是小菜一碟,它有一个很棒的界面。如果您正在寻找一个简单的托管解决方案,我认为值得一试。
回答by marko
回答by Jay Moorthi
Check out Tddium. Tddium support continuous integration, deployment and interactive testing of Ruby applications. It provides a managed environment with support for Selenium, Headless Webkit, and Solr. It hosts live Postgres, MySQL, Mongo, and Redis instances. And it automatically parallelizes large test suites.
查看Tddium。Tddium 支持 Ruby 应用程序的持续集成、部署和交互式测试。它提供了一个支持 Selenium、Headless Webkit 和 Solr 的托管环境。它托管实时 Postgres、MySQL、Mongo 和 Redis 实例。它会自动并行化大型测试套件。
回答by Vanuan
Travis CI has become popular in the ruby world: http://travis-ci.org/
Travis CI 在 ruby 世界变得流行:http: //travis-ci.org/
回答by csexton
回答by madlep
cruisecontrol.rb would be the perfect match then.
Cruisecontrol.rb 将是完美的匹配。

