From c79a9e22872e3b3a7629a2ae9577d9d88e265e5e Mon Sep 17 00:00:00 2001 From: Pit Kyzn Date: Mon, 19 Nov 2018 13:02:59 +0300 Subject: [PATCH] add example for flusing [tables] chains (#48858) add examples for: - iptables flush filter - iptables flush nat +label: docsite_pr --- lib/ansible/modules/system/iptables.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/lib/ansible/modules/system/iptables.py b/lib/ansible/modules/system/iptables.py index 3ae671055bc..839cf55489e 100644 --- a/lib/ansible/modules/system/iptables.py +++ b/lib/ansible/modules/system/iptables.py @@ -370,6 +370,19 @@ EXAMPLES = ''' - RST - SYN - FIN + +- name: iptables flush filter + iptables: + chain: "{{ item }}" + flush: yes + with_items: [ 'INPUT', 'FORWARD', 'OUTPUT' ] + +- name: iptables flush nat + iptables: + table: nat + chain: "{{ item }}" + flush: yes + with_items: [ 'INPUT', 'OUTPUT', 'PREROUTING', 'POSTROUTING' ] ''' import re