serverspec への matcher の追加方法に関する覚書。
serverspec のディレクトリ構成は以下のようになっています。
serverspec
├── bin
| // ==UserScript== | |
| // @name Query Cutter | |
| // @namespace http://www.ftnk.jp/userscripts | |
| // @description Cut '?ref=rss', and so on | |
| // @include http://* | |
| // ==/UserScript== | |
| (function (){ | |
| var newUrl = location.href; | |
| // delete rss for Cnet Japan, barks, etc |
| #!/usr/bin/ruby | |
| # -*- coding: utf-8 -*- | |
| $KCODE = "UTF8" | |
| require 'rubygems' | |
| require "mechanize" | |
| require "rexml/document" | |
| require "time" |
| #!/bin/sh | |
| # | |
| # munin plugin for Solaris kernel memory usage | |
| # | |
| #%# family=auto | |
| #%# capabilities=autoconf | |
| GREP=/bin/grep | |
| EGREP=/bin/egrep |
| require 'spec_helper' | |
| describe 'apache-22', :os => :solaris do | |
| it { should be_installed } | |
| end | |
| describe 'apache22', :os => :solaris do | |
| it { should be_enabled } | |
| it { should be_running } | |
| end |
| #!/usr/bin/python | |
| # python-munin (http://samuelks.com/python-munin/) を使って、 | |
| # cpu 使用率の plugin を書いてみた | |
| import commands | |
| from munin import MuninPlugin | |
| class CPUPlugin(MuninPlugin): | |
| title = "cpu usage (test)" |
| class ukigumo::server { | |
| package { | |
| [ | |
| 'pkg:/library/perl-5/amon2-512', | |
| 'pkg:/library/perl-5/text-xslate-512', | |
| 'pkg:/library/perl-5/text-xslate-bridge-tt2like-512', | |
| 'pkg:/library/perl-5/plack-middleware-reverseproxy-512', | |
| 'pkg:/library/perl-5/time-piece-512', | |
| 'pkg:/library/perl-5/sql-interp-512', |
serverspec への matcher の追加方法に関する覚書。
serverspec のディレクトリ構成は以下のようになっています。
serverspec
├── bin
| --- lib/puppet/provider/user/user_role_add.rb.bak 2014-05-29 23:37:58.360650493 +0900 | |
| +++ lib/puppet/provider/user/user_role_add.rb 2014-05-29 23:38:51.887938708 +0900 | |
| @@ -17,6 +17,7 @@ | |
| options :profiles, :flag => "-P" | |
| options :password_min_age, :flag => "-n" | |
| options :password_max_age, :flag => "-x" | |
| + options :shell, :flag => "-s" | |
| verify :gid, "GID must be an integer" do |value| | |
| value.is_a? Integer |
| # -*- coding: utf-8 -*- | |
| =begin | |
| とある技術ブログを読んで、いろいろと気になったので書いてみた | |
| properties はこんな感じ。 | |
| :mysql: | |
| :version: 5.6 | |
| :config: | |
| :groups: |