Adds file_cache_path support for chef_solo. [GH-1897]
Conflicts: CHANGELOG.md
This commit is contained in:
parent
986eda4a4f
commit
4713f146b4
|
@ -17,6 +17,7 @@ IMPROVEMENTS:
|
||||||
- Forwarded ports can specify a host IP and guest IP to bind to. [GH-1121]
|
- Forwarded ports can specify a host IP and guest IP to bind to. [GH-1121]
|
||||||
- You can now set the "ip" of a private network that uses DHCP. This will
|
- You can now set the "ip" of a private network that uses DHCP. This will
|
||||||
change the subnet and such that the DHCP server uses.
|
change the subnet and such that the DHCP server uses.
|
||||||
|
- Add `file_cache_path` support for chef_solo. [GH-1897]
|
||||||
|
|
||||||
BUG FIXES:
|
BUG FIXES:
|
||||||
|
|
||||||
|
|
|
@ -11,6 +11,7 @@ module VagrantPlugins
|
||||||
attr_accessor :nfs
|
attr_accessor :nfs
|
||||||
attr_accessor :encrypted_data_bag_secret_key_path
|
attr_accessor :encrypted_data_bag_secret_key_path
|
||||||
attr_accessor :encrypted_data_bag_secret
|
attr_accessor :encrypted_data_bag_secret
|
||||||
|
attr_accessor :file_cache_path
|
||||||
|
|
||||||
def initialize
|
def initialize
|
||||||
super
|
super
|
||||||
|
@ -19,9 +20,10 @@ module VagrantPlugins
|
||||||
@data_bags_path = UNSET_VALUE
|
@data_bags_path = UNSET_VALUE
|
||||||
@recipe_url = UNSET_VALUE
|
@recipe_url = UNSET_VALUE
|
||||||
@roles_path = UNSET_VALUE
|
@roles_path = UNSET_VALUE
|
||||||
|
@nfs = UNSET_VALUE
|
||||||
@encrypted_data_bag_secret = UNSET_VALUE
|
@encrypted_data_bag_secret = UNSET_VALUE
|
||||||
@encrypted_data_bag_secret_key_path = UNSET_VALUE
|
@encrypted_data_bag_secret_key_path = UNSET_VALUE
|
||||||
@nfs = UNSET_VALUE
|
@file_cache_path = UNSET_VALUE
|
||||||
|
|
||||||
@__defaulted_cookbooks_path = false
|
@__defaulted_cookbooks_path = false
|
||||||
end
|
end
|
||||||
|
@ -50,11 +52,13 @@ module VagrantPlugins
|
||||||
@data_bags_path = prepare_folders_config(@data_bags_path)
|
@data_bags_path = prepare_folders_config(@data_bags_path)
|
||||||
@roles_path = prepare_folders_config(@roles_path)
|
@roles_path = prepare_folders_config(@roles_path)
|
||||||
|
|
||||||
|
@nfs = false if @nfs == UNSET_VALUE
|
||||||
@encrypted_data_bag_secret = "/tmp/encrypted_data_bag_secret" if \
|
@encrypted_data_bag_secret = "/tmp/encrypted_data_bag_secret" if \
|
||||||
@encrypted_data_bag_secret == UNSET_VALUE
|
@encrypted_data_bag_secret == UNSET_VALUE
|
||||||
@encrypted_data_bag_secret_key_path = nil if \
|
@encrypted_data_bag_secret_key_path = nil if \
|
||||||
@encrypted_data_bag_secret_key_path == UNSET_VALUE
|
@encrypted_data_bag_secret_key_path == UNSET_VALUE
|
||||||
@nfs = false if @nfs == UNSET_VALUE
|
@file_cache_path = nil if \
|
||||||
|
@file_cache_path == UNSET_VALUE
|
||||||
end
|
end
|
||||||
|
|
||||||
def validate(machine)
|
def validate(machine)
|
||||||
|
|
|
@ -128,12 +128,12 @@ module VagrantPlugins
|
||||||
|
|
||||||
setup_config("provisioners/chef_solo/solo", "solo.rb", {
|
setup_config("provisioners/chef_solo/solo", "solo.rb", {
|
||||||
:node_name => @config.node_name,
|
:node_name => @config.node_name,
|
||||||
:provisioning_path => @config.provisioning_path,
|
|
||||||
:cookbooks_path => cookbooks_path,
|
:cookbooks_path => cookbooks_path,
|
||||||
:recipe_url => @config.recipe_url,
|
:recipe_url => @config.recipe_url,
|
||||||
:roles_path => roles_path,
|
:roles_path => roles_path,
|
||||||
:data_bags_path => data_bags_path,
|
:data_bags_path => data_bags_path,
|
||||||
:encrypted_data_bag_secret => @config.encrypted_data_bag_secret,
|
:encrypted_data_bag_secret => @config.encrypted_data_bag_secret,
|
||||||
|
:file_cache_path => @config.file_cache_path || @config.provisioning_path,
|
||||||
})
|
})
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<% if node_name %>
|
<% if node_name %>
|
||||||
node_name "<%= node_name %>"
|
node_name "<%= node_name %>"
|
||||||
<% end %>
|
<% end %>
|
||||||
file_cache_path "<%= provisioning_path %>"
|
file_cache_path "<%= file_cache_path %>"
|
||||||
cookbook_path <%= cookbooks_path.inspect %>
|
cookbook_path <%= cookbooks_path.inspect %>
|
||||||
<% if roles_path %>
|
<% if roles_path %>
|
||||||
role_path <%= roles_path.inspect %>
|
role_path <%= roles_path.inspect %>
|
||||||
|
|
Loading…
Reference in New Issue