module-nginx/templates/vhost/vhost_location_empty.erb
Daniel Black a66cd98ea9 Merge https://github.com/ese/puppet-nginx into hash
Resolved Conflicts:
	spec/defines/resource_location_spec.rb
	templates/vhost/vhost_location_alias.erb
	templates/vhost/vhost_location_directory.erb
	templates/vhost/vhost_location_empty.erb
	templates/vhost/vhost_location_fastcgi.erb
	templates/vhost/vhost_location_proxy.erb
	templates/vhost/vhost_location_stub_status.erb
2014-03-08 01:20:58 +11:00

21 lines
611 B
Text

location <%= @location %> {
<% if @location_custom_cfg -%><% @location_custom_cfg.sort_by {|k,v| k}.each do |key,value| -%>
<% if value.is_a?(Hash) -%><% value.each do |subkey,subvalue| -%>
<% Array(subkey).each do |asubkey| -%>
<% Array(subvalue).each do |asubvalue| -%>
<%= key %> <%= asubkey %> <%= asubvalue %>;
<% end %>
<% end %>
<% end -%><% else -%>
<% Array(value).each do |sub| -%>
<%= key %> <%= sub %>;
<% end %>
<%= key %> <%= subkey %> <%= subvalue %>;
<% end -%><% else -%>
<% Array(value).each do |sub| -%>
<%= key %> <%= sub %>;
<% end %>
<% end -%>
<% end -%><% end -%>
}