module-nginx/templates/vhost/vhost_location_stub_status.erb
Guzmán Brasó 49beb91993 James,
This is the best way I found to tackle the problem of custom directives, trying to
avoid common usage of module involve hacking the module/template to be able place
custom directives.

Right now support was added only for location context (default and custom ones),
it expects a hash with key value and it's supported on all current location types.

Added an example inside location.pp, usage it's pretty easy.
2012-10-02 23:35:56 -03:00

9 lines
309 B
Text

location <%= location %> {
<% if @location_cfg_prepend -%><% location_cfg_prepend.each do |key,value| -%>
<%= key %> <%= value %>;
<% end -%><% end -%>
stub_status on;
<% if @location_cfg_append -%><% location_cfg_append.each do |key,value| -%>
<%= key %> <%= value %>;
<% end -%><% end -%>
}