vagrant-chef-zero 1.0.1 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 95b7e4ea36f583297a2632a418172672668932c9
4
- data.tar.gz: b9a79fabb9e47bbf32588a1f6c7213c3e7656616
3
+ metadata.gz: 86af72a47a3512eea463c3aec69be38aca69b9a9
4
+ data.tar.gz: 81cb429011b8286dd13a03038f731478064e3797
5
5
  SHA512:
6
- metadata.gz: 4dc562a1fbb141e7b0518249dd3dfae3bc24704153cd984fa57c2478a4528d0893c2a3f2e8fd11e9d7933b64e9220efd70f2dfcfc691cb4deb41e6b72b0a3ee8
7
- data.tar.gz: 5b74aa9fdb90b29604d3b25d6931946368963cb32eecfb4dde778a569111abf68d9dd7cdbddf00da21e5bbab0bf7f517ef09d3998a44fafc1269f786199cd807
6
+ metadata.gz: ba482a0f7a01f7dcdf953f7d8e066c66e10196f7baa6b3859a3c12cd7e23a20e93c8f4f90eded3b5c4d6963b70185abf18586827dbcea58310356b6e59b3b2ec
7
+ data.tar.gz: 79ece92a106955bf87839db1192130db0741ff66d6649e4bd32f3a57971731eb3e7cbb3610d02c2a2ac907dfc3b67c66d1e9c6c2d83ebbde2abe46ba4900449e
@@ -1,9 +1,9 @@
1
1
  language: ruby
2
2
  notifications:
3
3
  email:
4
- - int-toolkit@schubergphilis.com
4
+ - mferreira@schubergphilis.com
5
5
  sudo: false
6
6
  cache: bundler
7
7
  rvm:
8
8
  - 2.1.2
9
- script: rake
9
+ script: bundle exec rake
@@ -1,3 +1,12 @@
1
+ ## 2.0.0
2
+
3
+ * Fix windows build (PR #73)
4
+ * Support for Vagrant 1.8 (PR #76)
5
+
6
+ ## 1.0.1
7
+
8
+ * Update licence in Gemspec
9
+
1
10
  ## 1.0.0
2
11
 
3
12
  * Allow using relative paths in plugin configuration (PR #27)
data/Gemfile CHANGED
@@ -18,10 +18,10 @@ group :development do
18
18
  end
19
19
 
20
20
  # Windows platform requirements to run chef-zero
21
- platforms :mswin, :mingw do
21
+ group :windows do
22
22
  gem "ruby-wmi"
23
23
  gem "win32-service"
24
- end
24
+ end if (RbConfig::CONFIG['host_os'] =~ /mswin|mingw|ming32/)
25
25
 
26
26
  # Force Vagrant to load our plugin during development (assume we are running from top level)
27
27
  group :plugins do
data/README.md CHANGED
@@ -1,7 +1,6 @@
1
1
  # Vagrant-Chef-Zero
2
2
  [![Build Status](https://travis-ci.org/schubergphilis/vagrant-chef-zero.svg)](https://travis-ci.org/schubergphilis/vagrant-chef-zero)
3
3
  [![Code Climate](https://codeclimate.com/github/schubergphilis/vagrant-chef-zero.png)](https://codeclimate.com/github/schubergphilis/vagrant-chef-zero)
4
- [![Dependency Status](https://gemnasium.com/schubergphilis/vagrant-chef-zero.png)](https://gemnasium.com/schubergphilis/vagrant-chef-zero)
5
4
  [![Coverage Status](https://coveralls.io/repos/schubergphilis/vagrant-chef-zero/badge.png)](https://coveralls.io/r/schubergphilis/vagrant-chef-zero)
6
5
  [![Gem Version](https://badge.fury.io/rb/vagrant-chef-zero.svg)](http://badge.fury.io/rb/vagrant-chef-zero)
7
6
 
@@ -1,5 +1,3 @@
1
- require 'chef'
2
-
3
1
  module VagrantPlugins
4
2
  module ChefZero
5
3
  module Action
@@ -67,9 +65,7 @@ module VagrantPlugins
67
65
  environments = select_items(path)
68
66
  environments.each do |e|
69
67
  if e =~ /.rb$/
70
- envrb = ::Chef::Environment.new
71
- envrb.from_file(e)
72
- environment = envrb.to_hash
68
+ env[:chef_zero].ui.error("Cannot upload environments defined in ruby files: #{e}")
73
69
  else
74
70
  environment = JSON.parse(IO.read(e)).to_hash
75
71
  end
@@ -90,9 +86,7 @@ module VagrantPlugins
90
86
  roles = select_items(path)
91
87
  roles.each do |r|
92
88
  if r =~ /.rb$/
93
- rrb = ::Chef::Role.new
94
- rrb.from_file(r)
95
- role = rrb.to_hash
89
+ env[:chef_zero].ui.error("Cannot upload roles defined in ruby files: #{r}")
96
90
  else
97
91
  role = JSON.parse(IO.read(r)).to_hash
98
92
  end
@@ -198,9 +192,7 @@ module VagrantPlugins
198
192
  end
199
193
  @conn
200
194
  end
201
-
202
195
  end
203
-
204
196
  end
205
197
  end
206
198
  end
@@ -1,6 +1,6 @@
1
1
  module VagrantPlugins
2
2
  module ChefZero
3
- VERSION = "1.0.1"
3
+ VERSION = "2.0.0"
4
4
  NAME = "vagrant-chef-zero"
5
5
 
6
6
  def self.describe(opts={})
@@ -0,0 +1,12 @@
1
+ *file
2
+ *file.lock
3
+ bin
4
+ bundle
5
+ chefignore
6
+ spec
7
+ test
8
+ vendor
9
+ .git
10
+ .*
11
+ dev.*
12
+ *_dev
@@ -0,0 +1,8 @@
1
+ name 'test_vagrant_chef_zero'
2
+ maintainer 'The Authors'
3
+ maintainer_email 'you@example.com'
4
+ license 'all_rights'
5
+ description 'Installs/Configures test_vagrant_chef_zero'
6
+ long_description 'Installs/Configures test_vagrant_chef_zero'
7
+ version '0.1.0'
8
+
@@ -0,0 +1 @@
1
+ log 'Converging test_vagrant_chef_zero::default'
@@ -0,0 +1,15 @@
1
+ {
2
+ "name": "test",
3
+ "description": "",
4
+ "cookbook_versions": {
5
+
6
+ },
7
+ "json_class": "Chef::Environment",
8
+ "chef_type": "environment",
9
+ "default_attributes": {
10
+
11
+ },
12
+ "override_attributes": {
13
+
14
+ }
15
+ }
@@ -0,0 +1,15 @@
1
+ {
2
+ "name": "test",
3
+ "description": "",
4
+ "cookbook_versions": {
5
+
6
+ },
7
+ "json_class": "Chef::Role",
8
+ "chef_type": "role",
9
+ "default_attributes": {
10
+
11
+ },
12
+ "override_attributes": {
13
+
14
+ }
15
+ }
@@ -0,0 +1,49 @@
1
+ # -*- mode: ruby -*-
2
+ # vi: set ft=ruby :
3
+
4
+ test_machines = {
5
+ 'windows' => {
6
+ 'box' => ENV['VAGRANT_TEST_WINDOWS_BOX'], # sbp_windows_2012_r2_20141211_1
7
+ 'communicator' => :winrm,
8
+ 'guest' => :windows
9
+ },
10
+ 'centos' => {
11
+ 'box' => ENV['VAGRANT_TEST_CENTOS_BOX'], # opscode-centos-7.1
12
+ 'communicator' => :ssh,
13
+ 'guest' => :linux
14
+ }
15
+ }
16
+
17
+ # Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
18
+ VAGRANTFILE_API_VERSION = "2"
19
+
20
+ Vagrant.configure(VAGRANTFILE_API_VERSION) do |global_config|
21
+ test_machines.each_pair do |name, options|
22
+ global_config.vm.define name do |config|
23
+
24
+ config.vm.box = options['box']
25
+
26
+ config.vm.communicator = options['communicator']
27
+ config.vm.guest = options['guest']
28
+
29
+ config.vm.provider 'virtualbox' do |vb|
30
+ vb.gui = true
31
+ end
32
+
33
+ config.berkshelf.enabled = true
34
+
35
+ config.omnibus.chef_version = 'latest'
36
+
37
+ config.chef_zero.cookbooks = [ '../fixtures/cookbooks' ]
38
+ config.chef_zero.environments = '../fixtures/environments'
39
+ config.chef_zero.roles = '../fixtures/roles'
40
+
41
+ config.vm.provision 'chef_client', run: 'always' do |chef|
42
+ chef.environment = 'test'
43
+ chef.add_role 'test'
44
+ chef.log_level = 'info'
45
+ chef.run_list = [ 'recipe[test_vagrant_chef_zero::default]' ]
46
+ end
47
+ end
48
+ end
49
+ end
@@ -5,11 +5,11 @@ Gem::Specification.new do |s|
5
5
  s.name = "vagrant-chef-zero"
6
6
  s.version = VagrantPlugins::ChefZero.get_version()
7
7
  s.platform = Gem::Platform::RUBY
8
- s.authors = "Andrew Gross"
9
- s.email = "andrew.w.gross@gmail.com"
10
- s.homepage = "http://github.com/andrewgross/vagrant-chef-zero"
11
- s.summary = "Enables Vagrant to interact with Chef Zero."
12
- s.description = "Enables Vagrant to interact with Chef Zero"
8
+ s.authors = "Andrew Gross, Miguel Ferreira, Timothy van Zadelhoff"
9
+ s.email = "andrew.w.gross@gmail.com, miguelferreira@me.com"
10
+ s.homepage = "http://github.com/schubergphilis/vagrant-chef-zero"
11
+ s.summary = "Enables Vagrant to spawn a Chef Zero instance that is shared by all VMs."
12
+ s.description = "Enables Vagrant to spawn a Chef Zero instance that is shared by all VMs."
13
13
 
14
14
  s.required_rubygems_version = ">= 1.3.6"
15
15
  s.rubyforge_project = "vagrant-chef-zero"
@@ -17,7 +17,6 @@ Gem::Specification.new do |s|
17
17
 
18
18
  s.add_dependency "chef-zero", "~> 2.0"
19
19
  s.add_dependency "ridley", ">= 1.0.0"
20
- s.add_dependency "chef", "~> 11.0"
21
20
 
22
21
  s.add_development_dependency "bump", "~> 0.5.2"
23
22
 
metadata CHANGED
@@ -1,80 +1,66 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-chef-zero
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
- - Andrew Gross
7
+ - Andrew Gross, Miguel Ferreira, Timothy van Zadelhoff
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-20 00:00:00.000000000 Z
11
+ date: 2016-01-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: chef-zero
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ~>
18
18
  - !ruby/object:Gem::Version
19
19
  version: '2.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ~>
25
25
  - !ruby/object:Gem::Version
26
26
  version: '2.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: ridley
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ">="
31
+ - - '>='
32
32
  - !ruby/object:Gem::Version
33
33
  version: 1.0.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ">="
38
+ - - '>='
39
39
  - !ruby/object:Gem::Version
40
40
  version: 1.0.0
41
- - !ruby/object:Gem::Dependency
42
- name: chef
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: '11.0'
48
- type: :runtime
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: '11.0'
55
41
  - !ruby/object:Gem::Dependency
56
42
  name: bump
57
43
  requirement: !ruby/object:Gem::Requirement
58
44
  requirements:
59
- - - "~>"
45
+ - - ~>
60
46
  - !ruby/object:Gem::Version
61
47
  version: 0.5.2
62
48
  type: :development
63
49
  prerelease: false
64
50
  version_requirements: !ruby/object:Gem::Requirement
65
51
  requirements:
66
- - - "~>"
52
+ - - ~>
67
53
  - !ruby/object:Gem::Version
68
54
  version: 0.5.2
69
- description: Enables Vagrant to interact with Chef Zero
70
- email: andrew.w.gross@gmail.com
55
+ description: Enables Vagrant to spawn a Chef Zero instance that is shared by all VMs.
56
+ email: andrew.w.gross@gmail.com, miguelferreira@me.com
71
57
  executables: []
72
58
  extensions: []
73
59
  extra_rdoc_files: []
74
60
  files:
75
- - ".gitignore"
76
- - ".ruby-version"
77
- - ".travis.yml"
61
+ - .gitignore
62
+ - .ruby-version
63
+ - .travis.yml
78
64
  - CHANGELOG.md
79
65
  - Gemfile
80
66
  - LICENSE.txt
@@ -118,8 +104,14 @@ files:
118
104
  - spec/vagrant-chef-zero/fixtures/nodes/boxer.json
119
105
  - spec/vagrant-chef-zero/fixtures/nodes/camel.json
120
106
  - spec/vagrant-chef-zero/fixtures/nodes/monkey.json
107
+ - test/fixtures/cookbooks/test_vagrant_chef_zero/chefignore
108
+ - test/fixtures/cookbooks/test_vagrant_chef_zero/metadata.rb
109
+ - test/fixtures/cookbooks/test_vagrant_chef_zero/recipes/default.rb
110
+ - test/fixtures/environments/test.json
111
+ - test/fixtures/roles/test.json
112
+ - test/integration/Vagrantfile
121
113
  - vagrant-chef-zero.gemspec
122
- homepage: http://github.com/andrewgross/vagrant-chef-zero
114
+ homepage: http://github.com/schubergphilis/vagrant-chef-zero
123
115
  licenses:
124
116
  - Apache v2.0
125
117
  metadata: {}
@@ -129,20 +121,20 @@ require_paths:
129
121
  - lib
130
122
  required_ruby_version: !ruby/object:Gem::Requirement
131
123
  requirements:
132
- - - ">="
124
+ - - '>='
133
125
  - !ruby/object:Gem::Version
134
126
  version: '0'
135
127
  required_rubygems_version: !ruby/object:Gem::Requirement
136
128
  requirements:
137
- - - ">="
129
+ - - '>='
138
130
  - !ruby/object:Gem::Version
139
131
  version: 1.3.6
140
132
  requirements: []
141
133
  rubyforge_project: vagrant-chef-zero
142
- rubygems_version: 2.4.4
134
+ rubygems_version: 2.0.14
143
135
  signing_key:
144
136
  specification_version: 4
145
- summary: Enables Vagrant to interact with Chef Zero.
137
+ summary: Enables Vagrant to spawn a Chef Zero instance that is shared by all VMs.
146
138
  test_files:
147
139
  - spec/lib/action/upload_spec.rb
148
140
  - spec/lib/config_spec.rb
@@ -168,4 +160,9 @@ test_files:
168
160
  - spec/vagrant-chef-zero/fixtures/nodes/boxer.json
169
161
  - spec/vagrant-chef-zero/fixtures/nodes/camel.json
170
162
  - spec/vagrant-chef-zero/fixtures/nodes/monkey.json
171
- has_rdoc:
163
+ - test/fixtures/cookbooks/test_vagrant_chef_zero/chefignore
164
+ - test/fixtures/cookbooks/test_vagrant_chef_zero/metadata.rb
165
+ - test/fixtures/cookbooks/test_vagrant_chef_zero/recipes/default.rb
166
+ - test/fixtures/environments/test.json
167
+ - test/fixtures/roles/test.json
168
+ - test/integration/Vagrantfile