Skip to content

Commit e3fa822

Browse files
dougmdanielsdeleo
authored andcommitted
[CHEF-1569] default windows bootstrap template
1 parent 5beb8f4 commit e3fa822

1 file changed

Lines changed: 30 additions & 0 deletions

File tree

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
cscript /nologo client-install.vbs <%= @config[:proxy] %>
2+
3+
> c:/chef/client.rb (
4+
@echo.log_level :info
5+
@echo.log_location STDOUT
6+
@echo.chef_server_url "<%= Chef::Config[:chef_server_url] %>"
7+
@echo.validation_client_name "<%= Chef::Config[:validation_client_name] %>"
8+
@echo.client_key "c:/chef/client.pem"
9+
@echo.validation_key "c:/chef/validation.pem"
10+
<% if Chef::Config[:http_proxy] != nil %>
11+
@echo.http_proxy "<%= Chef::Config[:http_proxy] %>"
12+
<% end %>
13+
<% if Chef::Config[:https_proxy] != nil %>
14+
@echo.https_proxy "<%= Chef::Config[:https_proxy] %>"
15+
<% end %>
16+
<% if Chef::Config[:no_proxy] != nil %>
17+
@echo.no_proxy "<%= Chef::Config[:no_proxy] %>"
18+
<% end %>
19+
<% if @config[:chef_node_name] == nil %>
20+
@echo.# Using default node name
21+
<% else %>
22+
@echo.node_name "<%= @config[:chef_node_name] %>"
23+
<% end %>
24+
)
25+
26+
> c:/chef/first-boot.json (
27+
@echo.<%= { "run_list" => @run_list }.to_json %>
28+
)
29+
30+
c:/ruby/bin/ruby c:/ruby/bin/chef-client -c c:/chef/client.rb -j c:/chef/first-boot.json -l <%= Chef::Config[:log_level] %>"

0 commit comments

Comments
 (0)