From 8dc63a2b7fe0bdc385e1f40c4ad7016230ba7b90 Mon Sep 17 00:00:00 2001 From: Nick Janetakis Date: Sun, 29 Jun 2014 16:26:02 -0400 Subject: [PATCH] Only output the maxretry when the user supplies it --- templates/etc/fail2ban/jail.local.j2 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/templates/etc/fail2ban/jail.local.j2 b/templates/etc/fail2ban/jail.local.j2 index 9caed53..9911ef1 100644 --- a/templates/etc/fail2ban/jail.local.j2 +++ b/templates/etc/fail2ban/jail.local.j2 @@ -30,7 +30,9 @@ enabled = {{ service.enabled|default("true") }} port = {{ service.port }} filter = {{ service.filter }} logpath = {{ service.logpath }} -maxretry = {{ service.maxretry|default(fail2ban_maxretry) }} +{% if service.maxretry is defined %} +maxretry = {{ service.maxretry }} +{% endif %} {% if service.protocol is defined %} protocol = {{ service.protocol }} {% endif %}