This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
config_path = "/etc/shorewall" | |
package "shorewall" | |
cookbook_file "/etc/default/shorewall" do | |
source "shorewall-enable" | |
mode 0644 | |
owner "root" | |
group "root" | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Rules Created by Chef | |
<% @rule_list.each do |rule| -%> | |
<%= rule %> | |
<% end -%> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name "appserver" | |
description "this is a sample chef role for an app server" | |
default_attributes "config" => { | |
"firewall" => { | |
"rules" => ["ACCEPT net fw tcp 80","ACCEPT net fw tcp 8080",ACCEPT net fw tcp 22"] | |
} | |
} | |
run_list( | |
"recipe[ror]", | |
"recipe[shorewall]" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/env/ruby | |
require 'net/http' | |
require 'rubygems' | |
require 'json' | |
require 'logger' | |
couch_server = "http://localhost:5984/" | |
active_tasks = ['_active_tasks'] | |
couch_db = 'chef/' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
file "/tmp/foo" do | |
notifies :run, resources(:execute => 'bobo') | |
notifies :restart, resources(:service => 'apache2') | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"id": "pacemaker", | |
"auth": "7db8f9aba89a6bc9f869cd1478f36dbb", | |
"nodes": [ | |
"chef01", | |
"chef02" | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ knife cookbook delete mongodb | |
$ knife cookbook upload mongodb -o cookbooks/ | |
$ knife cookbook download mongodb -d . | |
INFO: Downloading mongodb cookbook version 0.1.0 | |
INFO: Downloading resources | |
INFO: Downloading providers | |
INFO: Downloading recipes | |
INFO: Downloading definitions | |
INFO: Downloading libraries | |
INFO: Downloading attributes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Sun, 14 Nov 2010 01:50:46 +0000] DEBUG: Synchronizing cookbook auth | |
[Sun, 14 Nov 2010 01:50:46 +0000] DEBUG: String to sign: 'Method:GET | |
Hashed Path:1u8kI2jUaHFJ5x1wZm4S/AB/Ld0= | |
X-Ops-Content-Hash:2jmj7l5rSw0yVb/vlWAYkK/YBwk= | |
X-Ops-Timestamp:2010-11-14T01:50:46Z | |
Header hash: {"X-Ops-Content-Hash"=>"2jmj7l5rSw0yVb/vlWAYkK/YBwk=", "X-Ops-Authorization-1"=>"AgHD8CkkmxlIXqbOf479NIcJC33Oo2gJhiLhxvcG7Atpr8yG72C0Z/DRDXIR", "X-Ops-Userid"=>"chef03.ord.", "X-Ops-Sign"=>"version=1.0", "X-Ops-Authorization-2"=>"a85/evYTPbiQUIb3A241Jvluy1O81Y68EYiXSK8siUyoPary1IfKkIOiqrGx", "X-Ops-Authorization-3"=>"hNmhr0xLZ3UiGMuf4NDdloQ2MU0N7tHIdjLhuIcoSBZ/FOOiDaJzaeYn4X/I", "X-Ops-Authorization-4"=>"dLBh9iHg1D9PYQ+YR5VyErTT7l1GQDSnoKTK7m68u7DQwHfczY2SPHgY1l+s", "X-Ops-Authorization-5"=>"HdiRA+Dze1IRqX/MYDbfqNJMKJ91mWodByDqS5iJgXmfWZgW5qvsqFhGhl2Q", "X-Ops-Authorization-6"=>"iKGekZqvp8IEkQ9U5lgteVgl+bno+c7sCe/2rHKHEQ==", "X-Ops-Timestamp"=>"2010-11-14T01:50:46Z"} | |
[Sun, 14 Nov 2010 01:50:46 +0000] DEBUG: Sending HTTP Request via GET t |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
merb : chef-server (api) : worker (port 4000) ~ Started request handling: Mon Nov 15 21:59:15 +0000 2010 | |
merb : chef-server (api) : worker (port 4000) ~ Params: {"cookbook_version"=>"0.1.0", "action"=>"show_file", "checksum"=>"d41d8cd98f00b204e9800998ecf8427e", "cookbook_name"=>"base", "controller"=>"cookbooks"} | |
merb : chef-server (api) : worker (port 4000) ~ File with checksum d41d8cd98f00b204e9800998ecf8427e not found in the repository (this should not happen) - (Merb::ControllerExceptions::InternalServerError) | |
/usr/share/chef-server-api/app/controllers/cookbooks.rb:90:in `show_file' | |
/usr/lib/ruby/1.8/merb-core/controller/abstract_controller.rb:315:in `send' | |
/usr/lib/ruby/1.8/merb-core/controller/abstract_controller.rb:315:in `_call_action' | |
/usr/lib/ruby/1.8/merb-core/controller/abstract_controller.rb:289:in `_dispatch' | |
/usr/lib/ruby/1.8/merb-core/controller/merb_controller.rb:252:in `_dispatch' | |
/usr/lib/ruby/1.8/merb-core/dispatch/dispatcher.rb:102:in `dispatch_action' | |
/usr/lib/ruby/1.8/merb-core/dispatch/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sequel::AdapterNotFound -> LoadError: require 'mysql' did not define \ | |
Mysql::CLIENT_MULTI_RESULTS! You are probably using the pure ruby mysql.rb \ | |
driver, which Sequel does not support. You need to install the C based adapter, \ | |
and make sure that the mysql.so file is loaded instead of the mysql.rb file. |
OlderNewer