1 --- vagrant-1.7.4/plugins/provisioners/chef/plugin.rb 2015-08-19 17:03:47.474659244 +0300
2 +++ vagrant-1.7.4/plugins/provisioners/chef/plugin.rb 2015-08-19 17:28:22.723434523 +0300
4 Cap::Redhat::ChefInstall
7 + guest_capability(:pld, :chef_install) do
8 + require_relative "cap/pld/chef_install"
9 + Cap::PLD::ChefInstall
12 guest_capability(:omnios, :chef_installed) do
13 require_relative "cap/omnios/chef_installed"
14 Cap::OmniOS::ChefInstalled
17 + guest_capability(:pld, :chef_installed) do
18 + require_relative "cap/pld/chef_installed"
19 + Cap::PLD::ChefInstalled
22 guest_capability(:omnios, :chef_install) do
23 require_relative "cap/omnios/chef_install"
24 Cap::OmniOS::ChefInstall
25 --- /dev/null 2015-05-25 21:49:42.000000000 +0300
26 +++ vagrant-1.7.4/plugins/provisioners/chef/cap/pld/chef_installed.rb 2015-08-19 17:02:22.571070868 +0300
28 +module VagrantPlugins
32 + module ChefInstalled
33 + # Check if Chef is installed at the given version.
34 + # @return [true, false]
35 + def self.chef_installed(machine, version)
36 + knife = "/usr/bin/chef-client"
37 + command = "test -x #{knife}"
39 + if version != :latest
40 + command << "&& #{knife} --version | grep 'Chef: #{version}'"
43 + machine.communicate.test(command, sudo: true)
50 --- /dev/null 2015-05-25 21:49:42.000000000 +0300
51 +++ vagrant-1.7.4/plugins/provisioners/chef/cap/pld/chef_install.rb 2015-08-19 17:27:55.925638979 +0300
53 +require_relative "../../omnibus"
55 +module VagrantPlugins
60 + def self.chef_install(machine, version, prerelease, download_path)
61 + machine.communicate.sudo("poldek --up && poldek -u chef --noask")
63 + command = Omnibus.build_command(version, prerelease, download_path)
64 + machine.communicate.sudo(command)