问题描述
我使用我当前使用Capistrano的乘客在nginx上部署了动态配置的铁路应用实例的相当复杂的部署。我试图通过创建堆栈,层,实例和动态应用程序部署来自动化Opsworks上的整个过程。现有的Opsworks食谱都无法满足我的需要,因此我开始编写自己的自定义食谱。我正在尝试使用test-kitchen和vagrant测试它们,但是Opsworks食谱有太多自定义依赖项,无法在本地使用。因此,似乎我被困在要么只使用不依赖于Opsworks食谱的我自己的食谱来重新发明轮子,要么尝试在缓慢而昂贵的AWS上测试我的食谱。
I have a fairly complex deployment of dynamically configured instances of a rail apps on nginx using passenger that I currently use Capistrano for. I am trying to automate the entire process on Opsworks from creating the stack, layers, instances and dynamic app deployment. None of the existing Opsworks recipes come close to what I need so I started my own custom cookbooks. I am trying to test them using test-kitchen and vagrant but the Opsworks cookbooks have too many custom dependancies to be used locally. So it seems like I am stuck either re-inventing the wheel by using only my own recipes that don't depend on Opsworks cookbooks or trying to test my cookbooks on AWS which is slow and expensive.
有人在Opsworks上进行任何自定义菜谱开发吗?如果是,您如何对其进行测试?您在使用任何社区食谱吗?如果是,那么他们对使用Opsworks进行工作有多痛苦?
Is anybody doing any custom cookbook development on Opsworks and if so how are you testing it? Are you using any community cookbooks and if so how painful have they been to get working on Opsworks?
推荐答案
Opsworks现在支持Chef 11.10。和Berkshelf()来管理依赖关系,这使得使用自定义食谱成为可能。许多。
Opsworks now supports Chef 11.10 and Berkshelf (http://berkshelf.com/) to manage dependencies which makes using custom cookbooks so. much. easier.
我对Test Kitchen感到非常满意()与Vagrant& Chef Solo用于本地测试。
I've been pretty happy with Test Kitchen (https://github.com/test-kitchen/test-kitchen) with Vagrant & Chef Solo for local testing.
此外,您还可以从堆栈设置页面在Opsworks堆栈上手动运行特定配方。在这里查看:。
Additionally you can manually run particular recipes on an Opsworks stack from the stack settings page. Have a look here: http://docs.aws.amazon.com/opsworks/latest/userguide/workingcookbook-manual.html.
您还可以在Opsworks部署期间使用一些自定义JSON运行Cookbook测试:
You can also run cookbook tests during an Opsworks deployment with some custom JSON: http://docs.aws.amazon.com/opsworks/latest/userguide/troubleshoot-debug-test.html
这篇关于人们如何测试opsworks食谱?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!