Révision d43ced4d
Implement nftables:;simplerule::counter
templates/simplerule.epp | ||
---|---|---|
4 | 4 |
Optional[String] $proto, |
5 | 5 |
Optional[Variant[Stdlib::IP::Address::V6, Stdlib::IP::Address::V4, Pattern[/^@[-a-zA-Z0-9_]+$/]]] $daddr, |
6 | 6 |
Enum['ip', 'ip6'] $set_type, |
7 |
Boolean $counter, |
|
7 | 8 |
| -%> |
8 | 9 |
<%- if $proto { |
9 | 10 |
$_proto = $proto ? { |
... | ... | |
46 | 47 |
} else { |
47 | 48 |
$_comment = undef |
48 | 49 |
} -%> |
49 |
<%= regsubst(strip([$_ip_version_filter, $_dst_port, $_dst_hosts, $action, $_comment].join(' ')), '\s+', ' ', 'G') -%> |
|
50 |
<%- if $counter { |
|
51 |
$_counter = "counter" |
|
52 |
} else { |
|
53 |
$_counter = undef |
|
54 |
} -%> |
|
55 |
<%= regsubst(strip([$_ip_version_filter, $_dst_port, $_dst_hosts, $_counter, $action, $_comment].join(' ')), '\s+', ' ', 'G') -%> |
Formats disponibles : Unified diff