Skip to content

Commit 1278c8f

Browse files
committed
Merge git@github.com:btm/chef into btm
2 parents 6ee7d67 + 827da5e commit 1278c8f

7 files changed

Lines changed: 23 additions & 17 deletions

File tree

NOTICE

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,6 @@ Contributors and Copyright holders:
77

88
* Copyright 2008, Adam Jacob <adam@hjksolutions.com>
99
* Copyright 2008, Arjuna Christensen <aj@hjksolutions.com>
10+
* Copyright 2008, Bryan McLellan <btm@loftninjas.org>
1011
* Copyright 2008, Ezra Zygmuntowicz <ezra@engineyard.com>
11-
12+

README.txt

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,15 @@ RubyGems:
2020

2121
* stomp
2222
* stompserver
23-
* ultraviolet
2423
* facter
2524
* ferret
2625
* merb-core
26+
* merb-haml
2727
* haml
28-
* ruby-openid
28+
* ruby-openid (>= 2.0.1)
2929
* json
30+
* mongrel
31+
* rspec
3032

3133
External Servers:
3234

@@ -47,6 +49,16 @@ Install all of the above. To fire up a develpment environment, do the following
4749

4850
chef-server -N -c 2
4951

52+
* Test run chef to begin node registration:
53+
54+
sudo ./bin/chef-client -l debug -c ./examples/config/chef-solo.rb
55+
56+
* Validate the node registration:
57+
58+
Visit http://localhost:4000
59+
Login, enter an openid URL (see http://openid.net/get/)
60+
Registrations, click Validate
61+
5062
* Test run chef with:
5163

5264
chef-client -l debug

chef-server/bin/chef-indexer

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@
1818
# See the License for the specific language governing permissions and
1919
# limitations under the License.
2020

21+
require 'rubygems'
2122
require 'optparse'
2223
require 'chef'
23-
require 'rubygems'
2424
require 'facter'
2525

2626
config = {

chef/Rakefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# -*- ruby -*-
22
require 'rubygems'
33
require 'rake/gempackagetask'
4-
require './lib/chef.rb'
54
require './tasks/rspec.rb'
65

76
GEM = "chef"

chef/lib/chef/couchdb.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ def create_db
3737
end
3838

3939
def create_design_document(name, data)
40+
create_db
4041
to_update = true
4142
begin
4243
old_doc = @rest.get_rest("#{Chef::Config[:couchdb_database]}/_design%2F#{name}")
@@ -146,4 +147,4 @@ def safe_name(name)
146147
end
147148

148149
end
149-
end
150+
end

chef/tasks/rspec.rb

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,6 @@
22
require 'rake'
33
require 'spec/rake/spectask'
44

5-
#desc "Run all examples"
6-
#Spec::Rake::SpecTask.new('spec') do |t|
7-
# t.spec_files = FileList[File.join(File.dirname(__FILE__), "..", "spec", "**", "*.rb")]
8-
#end
9-
10-
require 'spec/rake/spectask'
11-
require 'spec/translator'
12-
135
CHEF_ROOT = File.join(File.dirname(__FILE__), "..")
146

157
task :default => :spec
@@ -51,4 +43,4 @@
5143
dir = CHEF_ROOT + '/spec'
5244
translator.translate(dir, dir)
5345
end
54-
end
46+
end

example-repository/Rakefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ require File.join(File.dirname(__FILE__), 'config', 'rake')
2222

2323
require 'tempfile'
2424

25-
$vcs = :svn
2625
if File.directory?(File.join(TOPDIR, ".svn"))
2726
$vcs = :svn
2827
elsif File.directory?(File.join(TOPDIR, ".git"))
@@ -47,6 +46,8 @@ task :update do
4746
else
4847
puts "* Skipping git pull, no origin specified"
4948
end
49+
else
50+
puts "* No SCM configured, skipping update"
5051
end
5152
end
5253

@@ -171,4 +172,4 @@ EOH
171172
sh("(cd #{CADIR} && openssl x509 -noout -fingerprint -text < #{fqdn}.crt > #{fqdn}.info)")
172173
sh("(cd #{CADIR} && cat #{fqdn}.crt #{fqdn}.key > #{fqdn}.pem)")
173174
sh("(cd #{CADIR} && chmod 644 #{fqdn}.pem)")
174-
end
175+
end

0 commit comments

Comments
 (0)