mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 01:18:58 +00:00
Merge pull request #11850 from zeezooz/iptables_pknock_name
Allow name argument for pknock iptables module.
This commit is contained in:
commit
93f9222ade
@ -136,7 +136,7 @@ def build_rule(table=None, chain=None, command=None, position='', full=None, fam
|
||||
kwargs['match'] = kwargs['match'].split(',')
|
||||
for match in kwargs['match']:
|
||||
rule += '-m {0} '.format(match)
|
||||
if 'name' in kwargs and match.strip() in ('quota2', 'recent'):
|
||||
if 'name' in kwargs and match.strip() in ('pknock', 'quota2', 'recent'):
|
||||
rule += '--name {0} '.format(kwargs['name'])
|
||||
del kwargs['match']
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user