Debian Codegraph @

templates/fragments/_options.epp

raw
1 <% if $_sort_options_alphabetic == true { -%>
2 <% $option_order = {} -%>
3 <% } else { -%>
4 <% $option_order = {
5 'acl' => -1,
6 'tcp-request' => 2,
7 'block' => 3,
8 'http-request' => 4,
9 'reqallow' => 5,
10 'reqdel' => 5,
11 'reqdeny' => 5,
12 'reqidel' => 5,
13 'reqideny' => 5,
14 'reqipass' => 5,
15 'reqirep' => 5,
16 'reqitarpit' => 5,
17 'reqpass' => 5,
18 'reqrep' => 5,
19 'reqtarpit' => 5,
20 'reqadd' => 6,
21 'redirect' => 7,
22 'use_backend' => 8,
23 'default_backend' => 9,
24 'use-server' => 9,
25 'option' => 10,
26 'http-check' => 11,
27 'server' => 100,
28 } -%>
29 <% } -%>
30 <% if String(type($options, 'generalized')).index('Array') == 0 { -%>
31 <% $options.each |$option| { -%>
32 <%= epp('haproxy/haproxy_options_sorting.epp', { 'options' => $option, 'option_order' => $option_order }) -%>
33 <% } -%>
34 <% } elsif String(type($options, 'generalized')).index('Hash') == 0 { -%>
35 <%= epp('haproxy/haproxy_options_sorting.epp', { 'options' => $options, 'option_order' => $option_order }) -%>
36 <% } -%>