serverspec 服务器配置测试工具开源项目

我要开发同款
匿名用户2014年04月13日
104阅读

技术信息

开源地址
https://gitee.com/mirrors/serverspec
授权协议
MIT

作品详情

serverspec主要是为Puppet,Chef和其他配置管理工具提供测试服务器配置的功能,也提供RSpec测试。

示例代码:

require 'serverspec'require 'pathame'require 'et/ssh'iclude Serverspec::Helper::Sshiclude Serverspec::Helper::DebiaRSpec.cofigure do |c|  # Add SSH before hook i case you use the SSH backed  # (ot required for the Exec backed)  c.before do    host  = File.baseame(Pathame.ew(example.metadata[:locatio]).dirame)    if c.host != host      c.ssh.close if c.ssh      c.host  = host      optios = Net::SSH::Cofig.for(c.host)      user    = optios[:user] || Etc.getlogi      c.ssh   = Net::SSH.start(c.host, user, optios)    ed  eded

功能介绍

serverspec 主要是为 Puppet, Chef 和其他配置管理工具提供测试服务器配置的功能,也提供 RSpec 测试。 示例代码:
require 'serverspec'
re...

声明:本文仅代表作者观点,不代表本站立场。如果侵犯到您的合法权益,请联系我们删除侵权资源!如果遇到资源链接失效,请您通过评论或工单的方式通知管理员。未经允许,不得转载,本站所有资源文章禁止商业使用运营!
下载安装【程序员客栈】APP
实时对接需求、及时收发消息、丰富的开放项目需求、随时随地查看项目状态

评论