knife_sous 0.0.1 → 0.1.0pre

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 12f12c0d9fc05adff47a4b537620423eb46aa86f
4
+ data.tar.gz: e49c05ceeb12b09b0bf3a26d07ca2ba0d90e58a7
5
+ SHA512:
6
+ metadata.gz: 26a30033b1caafb772dde6eaee684a0b0c58fc615dbf31577887d38bee50de65beb0ab52ca4eb299cacf278cd76ccb49d3204c8a624b34fbf8b3b5cfa37cd876
7
+ data.tar.gz: becdfeae62f8812bc341afda3567e42f0f31b4c23d382a24c99eb3b388220f4b52881d58bb8cf50e467d84fc5595e7080038d8dc4cff5d8738f7d1fa19c2ab00
data/.gitignore CHANGED
@@ -1 +1,2 @@
1
1
  tmp
2
+ *.gem
data/.ruby-gemset ADDED
@@ -0,0 +1,2 @@
1
+ knife_sous
2
+
data/.ruby-version CHANGED
@@ -1 +1,2 @@
1
- ruby-1.9.3-p362@knife_sous
1
+ ruby-2.0.0-p247
2
+
@@ -0,0 +1,2 @@
1
+ ruby-2.0.0-p0
2
+
data/Gemfile CHANGED
@@ -5,5 +5,4 @@ gemspec
5
5
  gem 'guard'
6
6
  gem 'guard-rspec'
7
7
  gem 'pry'
8
- gem 'rb-fsevent'
9
8
 
data/Gemfile.lock CHANGED
@@ -1,14 +1,13 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- knife_sous (0.0.1)
5
- knife-solo (~> 0.2.0)
4
+ knife_sous (0.1.0pre)
5
+ knife-solo (~> 0.3.0)
6
6
 
7
7
  GEM
8
8
  remote: http://rubygems.org/
9
9
  specs:
10
- archive-tar-minitar (0.5.2)
11
- chef (11.4.0)
10
+ chef (11.6.0)
12
11
  erubis
13
12
  highline (>= 1.6.9)
14
13
  json (>= 1.4.4, <= 1.7.7)
@@ -22,47 +21,47 @@ GEM
22
21
  ohai (>= 0.6.0)
23
22
  rest-client (>= 1.0.4, < 1.7.0)
24
23
  yajl-ruby (~> 1.1)
25
- coderay (1.0.8)
26
- diff-lcs (1.1.3)
24
+ coderay (1.0.9)
25
+ diff-lcs (1.2.4)
27
26
  erubis (2.7.0)
28
- guard (1.6.2)
29
- listen (>= 0.6.0)
27
+ ffi (1.9.0)
28
+ formatador (0.2.4)
29
+ guard (1.8.2)
30
+ formatador (>= 0.2.4)
31
+ listen (>= 1.0.0)
30
32
  lumberjack (>= 1.0.2)
31
33
  pry (>= 0.9.10)
32
- terminal-table (>= 1.4.3)
33
34
  thor (>= 0.14.6)
34
- guard-rspec (2.4.0)
35
- guard (>= 1.1)
36
- rspec (~> 2.11)
37
- highline (1.6.15)
35
+ guard-rspec (3.0.2)
36
+ guard (>= 1.8)
37
+ rspec (~> 2.13)
38
+ highline (1.6.19)
38
39
  ipaddress (0.8.0)
39
40
  json (1.7.7)
40
- knife-solo (0.2.0)
41
+ knife-solo (0.3.0)
41
42
  chef (>= 10.12)
42
- librarian (~> 0.0.20)
43
+ erubis (~> 2.7.0)
43
44
  net-ssh (>= 2.2.2, < 3.0)
44
- librarian (0.0.26)
45
- archive-tar-minitar (>= 0.5.2)
46
- chef (>= 0.10)
47
- highline
48
- thor (~> 0.15)
49
- listen (0.7.2)
50
- lumberjack (1.0.2)
51
- method_source (0.8.1)
52
- mime-types (1.21)
45
+ listen (1.3.0)
46
+ rb-fsevent (>= 0.9.3)
47
+ rb-inotify (>= 0.9)
48
+ rb-kqueue (>= 0.2)
49
+ lumberjack (1.0.4)
50
+ method_source (0.8.2)
51
+ mime-types (1.24)
53
52
  mixlib-authentication (1.3.0)
54
53
  mixlib-log
55
54
  mixlib-cli (1.3.0)
56
55
  mixlib-config (1.1.2)
57
- mixlib-log (1.4.1)
58
- mixlib-shellout (1.1.0)
59
- net-ssh (2.6.5)
56
+ mixlib-log (1.6.0)
57
+ mixlib-shellout (1.2.0)
58
+ net-ssh (2.6.8)
60
59
  net-ssh-gateway (1.2.0)
61
60
  net-ssh (>= 2.6.5)
62
61
  net-ssh-multi (1.1)
63
62
  net-ssh (>= 2.1.4)
64
63
  net-ssh-gateway (>= 0.99.0)
65
- ohai (6.16.0)
64
+ ohai (6.18.0)
66
65
  ipaddress
67
66
  mixlib-cli
68
67
  mixlib-config
@@ -70,37 +69,39 @@ GEM
70
69
  mixlib-shellout
71
70
  systemu
72
71
  yajl-ruby
73
- pry (0.9.11.4)
72
+ pry (0.9.12.2)
74
73
  coderay (~> 1.0.5)
75
74
  method_source (~> 0.8)
76
75
  slop (~> 3.4)
77
- rake (10.0.3)
76
+ rake (10.1.0)
78
77
  rb-fsevent (0.9.3)
78
+ rb-inotify (0.9.1)
79
+ ffi (>= 0.5.0)
80
+ rb-kqueue (0.2.0)
81
+ ffi (>= 0.5.0)
79
82
  rest-client (1.6.7)
80
83
  mime-types (>= 1.16)
81
- rspec (2.12.0)
82
- rspec-core (~> 2.12.0)
83
- rspec-expectations (~> 2.12.0)
84
- rspec-mocks (~> 2.12.0)
85
- rspec-core (2.12.2)
86
- rspec-expectations (2.12.1)
87
- diff-lcs (~> 1.1.3)
88
- rspec-mocks (2.12.1)
89
- slop (3.4.3)
84
+ rspec (2.14.1)
85
+ rspec-core (~> 2.14.0)
86
+ rspec-expectations (~> 2.14.0)
87
+ rspec-mocks (~> 2.14.0)
88
+ rspec-core (2.14.5)
89
+ rspec-expectations (2.14.2)
90
+ diff-lcs (>= 1.1.3, < 2.0)
91
+ rspec-mocks (2.14.3)
92
+ slop (3.4.6)
90
93
  systemu (2.5.2)
91
- terminal-table (1.4.5)
92
- thor (0.17.0)
94
+ thor (0.18.1)
93
95
  yajl-ruby (1.1.0)
94
96
 
95
97
  PLATFORMS
96
98
  ruby
97
99
 
98
100
  DEPENDENCIES
99
- bundler (~> 1.1)
101
+ bundler (~> 1.3.5)
100
102
  guard
101
103
  guard-rspec
102
104
  knife_sous!
103
105
  pry
104
- rake (~> 10.0.0)
105
- rb-fsevent
106
- rspec (~> 2.12.0)
106
+ rake (~> 10.1.0)
107
+ rspec (~> 2.14.1)
data/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2013 Shaun Dern
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/knife_sous.gemspec CHANGED
@@ -6,7 +6,7 @@ Gem::Specification.new do |s|
6
6
  s.email = "shaun@substantail.com"
7
7
 
8
8
  s.name = 'knife_sous'
9
- s.version = "0.0.1"
9
+ s.version = "0.1.0pre"
10
10
  s.description = %q{Knife plugin for managing knife-solo nodes}
11
11
  s.summary = %q{A Chef Knife plugin which uses a DSL to configure and
12
12
  manage knife solo nodes. Run knife solo commands on one or multiple nodes.}
@@ -20,9 +20,9 @@ manage knife solo nodes. Run knife solo commands on one or multiple nodes.}
20
20
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
21
21
  s.require_paths = ["lib"]
22
22
 
23
- s.add_development_dependency "rspec", "~> 2.12.0"
24
- s.add_development_dependency "rake", "~> 10.0.0"
25
- s.add_development_dependency "bundler", "~> 1.1"
26
- s.add_dependency "knife-solo", "~> 0.2.0"
23
+ s.add_development_dependency "rspec", "~> 2.14.1"
24
+ s.add_development_dependency "rake", "~> 10.1.0"
25
+ s.add_development_dependency "bundler", "~> 1.3.5"
26
+ s.add_dependency "knife-solo", "~> 0.3.0"
27
27
  end
28
28
 
@@ -1,4 +1,5 @@
1
1
  require 'knife_sous/namespace'
2
+ require 'knife_sous/root_namespace'
2
3
 
3
4
  module KnifeSous
4
5
  module ProcessorCommand
@@ -43,7 +44,7 @@ module KnifeSous
43
44
 
44
45
  def process_config
45
46
  validate_config!
46
- root_namespace = Namespace.new('')
47
+ root_namespace = RootNamespace.new
47
48
  root_namespace.instance_eval(File.read(manifest_file_path), manifest_file_path)
48
49
  root_namespace
49
50
  end
@@ -0,0 +1,14 @@
1
+ require 'knife_sous/node'
2
+
3
+ require 'knife_sous/dsl_definitions'
4
+ require 'knife_sous/dsl_wrapper'
5
+
6
+
7
+ module KnifeSous
8
+ class RootNamespace < Namespace
9
+ def initialize
10
+ @name = ""
11
+ end
12
+ end
13
+ end
14
+
@@ -20,40 +20,5 @@ describe KnifeSous::Namespace do
20
20
  KnifeSous::Namespace.new(:foo_bar).name.should == 'foo_bar'
21
21
  end
22
22
  end
23
-
24
- describe "root namespace" do
25
- it "should instance_eval DSL from file" do
26
- root_namespace = KnifeSous::Namespace.new('')
27
- root_namespace.instance_eval do
28
- namespace :production do |prod|
29
- prod.node :node_awesome
30
- prod.namespace :web do |web|
31
- web.node :web_node
32
- end
33
- end
34
- node :vagrant, node_config: 'nodes/some_node.json', ssh_config: 'vagrant config'
35
- end
36
-
37
- prod_namespace = root_namespace[0]
38
- prod_namespace.should be_a KnifeSous::Namespace
39
- prod_namespace.name.should == 'production'
40
-
41
- vagrant_node = root_namespace[1]
42
- vagrant_node.should be_a KnifeSous::Node
43
- vagrant_node.name.should == 'vagrant'
44
-
45
- node_awesome = prod_namespace[0]
46
- node_awesome.should be_a KnifeSous::Node
47
- node_awesome.name.should == 'node_awesome'
48
-
49
- web_namespace = prod_namespace[1]
50
- web_namespace.should be_a KnifeSous::Namespace
51
- web_namespace.name.should == 'web'
52
-
53
- web_node = web_namespace[0]
54
- web_node.should be_a KnifeSous::Node
55
- web_node.name.should == 'web_node'
56
- end
57
- end
58
23
  end
59
24
 
@@ -0,0 +1,37 @@
1
+ require 'spec_helper'
2
+
3
+ describe KnifeSous::Namespace do
4
+ it "should instance_eval DSL from file" do
5
+ root_namespace = KnifeSous::RootNamespace.new
6
+ root_namespace.instance_eval do
7
+ namespace :production do |prod|
8
+ prod.node :node_awesome
9
+ prod.namespace :web do |web|
10
+ web.node :web_node
11
+ end
12
+ end
13
+ node :vagrant, node_config: 'nodes/some_node.json', ssh_config: 'vagrant config'
14
+ end
15
+
16
+ prod_namespace = root_namespace[0]
17
+ prod_namespace.should be_a KnifeSous::Namespace
18
+ prod_namespace.name.should == 'production'
19
+
20
+ vagrant_node = root_namespace[1]
21
+ vagrant_node.should be_a KnifeSous::Node
22
+ vagrant_node.name.should == 'vagrant'
23
+
24
+ node_awesome = prod_namespace[0]
25
+ node_awesome.should be_a KnifeSous::Node
26
+ node_awesome.name.should == 'node_awesome'
27
+
28
+ web_namespace = prod_namespace[1]
29
+ web_namespace.should be_a KnifeSous::Namespace
30
+ web_namespace.name.should == 'web'
31
+
32
+ web_node = web_namespace[0]
33
+ web_node.should be_a KnifeSous::Node
34
+ web_node.name.should == 'web_node'
35
+ end
36
+ end
37
+
metadata CHANGED
@@ -1,80 +1,71 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: knife_sous
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
5
- prerelease:
4
+ version: 0.1.0pre
6
5
  platform: ruby
7
6
  authors:
8
7
  - Shaun Dern
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-02-15 00:00:00.000000000 Z
11
+ date: 2013-08-21 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: rspec
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
17
  - - ~>
20
18
  - !ruby/object:Gem::Version
21
- version: 2.12.0
19
+ version: 2.14.1
22
20
  type: :development
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
24
  - - ~>
28
25
  - !ruby/object:Gem::Version
29
- version: 2.12.0
26
+ version: 2.14.1
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: rake
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
31
  - - ~>
36
32
  - !ruby/object:Gem::Version
37
- version: 10.0.0
33
+ version: 10.1.0
38
34
  type: :development
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
38
  - - ~>
44
39
  - !ruby/object:Gem::Version
45
- version: 10.0.0
40
+ version: 10.1.0
46
41
  - !ruby/object:Gem::Dependency
47
42
  name: bundler
48
43
  requirement: !ruby/object:Gem::Requirement
49
- none: false
50
44
  requirements:
51
45
  - - ~>
52
46
  - !ruby/object:Gem::Version
53
- version: '1.1'
47
+ version: 1.3.5
54
48
  type: :development
55
49
  prerelease: false
56
50
  version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
51
  requirements:
59
52
  - - ~>
60
53
  - !ruby/object:Gem::Version
61
- version: '1.1'
54
+ version: 1.3.5
62
55
  - !ruby/object:Gem::Dependency
63
56
  name: knife-solo
64
57
  requirement: !ruby/object:Gem::Requirement
65
- none: false
66
58
  requirements:
67
59
  - - ~>
68
60
  - !ruby/object:Gem::Version
69
- version: 0.2.0
61
+ version: 0.3.0
70
62
  type: :runtime
71
63
  prerelease: false
72
64
  version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
65
  requirements:
75
66
  - - ~>
76
67
  - !ruby/object:Gem::Version
77
- version: 0.2.0
68
+ version: 0.3.0
78
69
  description: Knife plugin for managing knife-solo nodes
79
70
  email: shaun@substantail.com
80
71
  executables: []
@@ -82,10 +73,13 @@ extensions: []
82
73
  extra_rdoc_files: []
83
74
  files:
84
75
  - .gitignore
76
+ - .ruby-gemset
85
77
  - .ruby-version
78
+ - .ruby-version.example
86
79
  - Gemfile
87
80
  - Gemfile.lock
88
81
  - Guardfile
82
+ - LICENSE
89
83
  - README.md
90
84
  - Rakefile
91
85
  - knife_sous.gemspec
@@ -106,6 +100,7 @@ files:
106
100
  - lib/knife_sous/node_command.rb
107
101
  - lib/knife_sous/node_presenter.rb
108
102
  - lib/knife_sous/processor_command.rb
103
+ - lib/knife_sous/root_namespace.rb
109
104
  - lib/templates/nodes.example.rb
110
105
  - spec/lib/chef/knife/sous_bootstrap_spec.rb
111
106
  - spec/lib/chef/knife/sous_clean_spec.rb
@@ -122,6 +117,7 @@ files:
122
117
  - spec/lib/knife_sous/node_presenter_spec.rb
123
118
  - spec/lib/knife_sous/node_spec.rb
124
119
  - spec/lib/knife_sous/processor_command_spec.rb
120
+ - spec/lib/knife_sous/root_namespace_spec.rb
125
121
  - spec/spec_helper.rb
126
122
  - spec/support/fixtures/nodes.rb
127
123
  - spec/support/knife_command_helpers.rb
@@ -131,27 +127,26 @@ files:
131
127
  homepage: http://github.com/substantial/knife_sous
132
128
  licenses:
133
129
  - MIT
130
+ metadata: {}
134
131
  post_install_message:
135
132
  rdoc_options: []
136
133
  require_paths:
137
134
  - lib
138
135
  required_ruby_version: !ruby/object:Gem::Requirement
139
- none: false
140
136
  requirements:
141
- - - ! '>='
137
+ - - '>='
142
138
  - !ruby/object:Gem::Version
143
139
  version: '0'
144
140
  required_rubygems_version: !ruby/object:Gem::Requirement
145
- none: false
146
141
  requirements:
147
- - - ! '>='
142
+ - - '>'
148
143
  - !ruby/object:Gem::Version
149
- version: '0'
144
+ version: 1.3.1
150
145
  requirements: []
151
146
  rubyforge_project: knife_sous
152
- rubygems_version: 1.8.24
147
+ rubygems_version: 2.0.6
153
148
  signing_key:
154
- specification_version: 3
149
+ specification_version: 4
155
150
  summary: A Chef Knife plugin which uses a DSL to configure and manage knife solo nodes.
156
151
  Run knife solo commands on one or multiple nodes.
157
152
  test_files:
@@ -170,6 +165,7 @@ test_files:
170
165
  - spec/lib/knife_sous/node_presenter_spec.rb
171
166
  - spec/lib/knife_sous/node_spec.rb
172
167
  - spec/lib/knife_sous/processor_command_spec.rb
168
+ - spec/lib/knife_sous/root_namespace_spec.rb
173
169
  - spec/spec_helper.rb
174
170
  - spec/support/fixtures/nodes.rb
175
171
  - spec/support/knife_command_helpers.rb