Adds formatter option to Chef Provisioner [GH-1250]
This commit is contained in:
parent
931e23c5d0
commit
5c2c5b9999
|
@ -7,6 +7,7 @@ module VagrantPlugins
|
|||
attr_accessor :binary_path
|
||||
attr_accessor :binary_env
|
||||
attr_accessor :custom_config_path
|
||||
attr_accessor :formatter
|
||||
attr_accessor :http_proxy
|
||||
attr_accessor :http_proxy_user
|
||||
attr_accessor :http_proxy_pass
|
||||
|
@ -31,6 +32,7 @@ module VagrantPlugins
|
|||
@binary_path = UNSET_VALUE
|
||||
@binary_env = UNSET_VALUE
|
||||
@custom_config_path = UNSET_VALUE
|
||||
@formatter = UNSET_VALUE
|
||||
@http_proxy = UNSET_VALUE
|
||||
@http_proxy_user = UNSET_VALUE
|
||||
@http_proxy_pass = UNSET_VALUE
|
||||
|
@ -55,6 +57,7 @@ module VagrantPlugins
|
|||
@binary_path = nil if @binary_path == UNSET_VALUE
|
||||
@binary_env = nil if @binary_env == UNSET_VALUE
|
||||
@custom_config_path = nil if @custom_config_path == UNSET_VALUE
|
||||
@formatter = nil if @formatter == UNSET_VALUE
|
||||
@http_proxy = nil if @http_proxy == UNSET_VALUE
|
||||
@http_proxy_user = nil if @http_proxy_user == UNSET_VALUE
|
||||
@http_proxy_pass = nil if @http_proxy_pass == UNSET_VALUE
|
||||
|
|
|
@ -71,7 +71,8 @@ module VagrantPlugins
|
|||
:https_proxy_user => @config.https_proxy_user,
|
||||
:https_proxy_pass => @config.https_proxy_pass,
|
||||
:log_level => @config.log_level.to_sym,
|
||||
:no_proxy => @config.no_proxy
|
||||
:no_proxy => @config.no_proxy,
|
||||
:formatter => @config.formatter
|
||||
}.merge(template_vars))
|
||||
|
||||
# Create a temporary file to store the data so we
|
||||
|
|
|
@ -32,6 +32,10 @@ pid_file "/var/run/chef/chef-client.pid"
|
|||
|
||||
Mixlib::Log::Formatter.show_time = true
|
||||
|
||||
<% if formatter %>
|
||||
formatter "<%= formatter %>"
|
||||
<% end %>
|
||||
|
||||
<% if custom_configuration -%>
|
||||
load "<%= custom_configuration %>"
|
||||
<% end -%>
|
||||
|
|
|
@ -28,6 +28,10 @@ https_proxy_user <%= https_proxy_user.inspect %>
|
|||
https_proxy_pass <%= https_proxy_pass.inspect %>
|
||||
no_proxy <%= no_proxy.inspect %>
|
||||
|
||||
<% if formatter %>
|
||||
formatter "<%= formatter %>"
|
||||
<% end %>
|
||||
|
||||
<% if custom_configuration -%>
|
||||
load "<%= custom_configuration %>"
|
||||
<% end -%>
|
||||
|
|
Loading…
Reference in New Issue