I was trying some TDD with [Tesk-Kitchen][1] and [ServerSpec][2] when I found myself in the following case scenario:
I have a integration test like this:
# cookbook_webtest/test/integration/default/serverspec/localhost/webtest_spec.rb
#!/bin/bash | |
docker stop $(docker ps -a -q) | |
docker rm -f $(docker ps -a -q) | |
docker rmi -f $(docker images -q) |
diff --git a/providers/service_runit.rb b/providers/service_runit.rb | |
index 5352726..1437a10 100644 | |
--- a/providers/service_runit.rb | |
+++ b/providers/service_runit.rb | |
@@ -31,6 +31,10 @@ action :disable do | |
set_updated { manage_runit_service(:disable) } | |
end | |
+action :restart do | |
+ set_updated { manage_runit_service(:restart) } |
Note: total experiment and hack, looks nasty, could be awesome:
kitchen.local.yml
into $HOME/.kitchen/config.yml
brew install polipo
, with Ubuntu: apt-get install polipo
)polipo-start
and polipo-console
somewhere useful (perhaps $HOME/bin
?)# This recipe is unused | |
# Please use RVM-Plugin for Jenkins | |
include_recipe "jenkins" | |
script "Install RVM to jenkins" do | |
interpreter "bash" | |
not_if {::File.exists?("/var/lib/jenkins/.rvm")} | |
code <<-EOH | |
sudo -u jenkins bash -c ' |
ruby_block 'remove_dynamically_oneshot' do | |
block { node.run_list.remove('recipe[mycookbook::oneshot]') } | |
end |
# -*- mode: ruby; coding: utf-8; -*- | |
source "https://api.berkshelf.com" | |
#source "https://supermarket.getchef.com" | |
cookbook 'chef-client', '~> 3.6.0' |
SELECT table_schema, | |
table_name, | |
data_type, | |
( CASE data_type | |
WHEN 'tinyint' THEN 255 | |
WHEN 'smallint' THEN 65535 | |
WHEN 'mediumint' THEN 16777215 | |
WHEN 'int' THEN 4294967295 | |
WHEN 'bigint' THEN 18446744073709551615 | |
end >> IF(Locate('unsigned', column_type) > 0, 0, 1) ) AS MAX_VALUE, |
#!/bin/bash | |
# ================================================================== | |
# ______ __ _____ | |
# /_ __/___ ____ ___ _________ _/ /_ /__ / | |
# / / / __ \/ __ `__ \/ ___/ __ `/ __/ / / | |
# / / / /_/ / / / / / / /__/ /_/ / /_ / / | |
#/_/ \____/_/ /_/ /_/\___/\__,_/\__/ /_/ | |
# Multi-instance Apache Tomcat installation with a focus | |
# on best-practices as defined by Apache, SpringSource, and MuleSoft |
#! /bin/sh | |
# ================================================================== | |
# ______ __ _____ | |
# /_ __/___ ____ ___ _________ _/ /_ /__ / | |
# / / / __ \/ __ `__ \/ ___/ __ `/ __/ / / | |
# / / / /_/ / / / / / / /__/ /_/ / /_ / / | |
#/_/ \____/_/ /_/ /_/\___/\__,_/\__/ /_/ | |
# Multi-instance Apache Tomcat installation with a focus | |
# on best-practices as defined by Apache, SpringSource, and MuleSoft |