I have a mixed Ubuntu 16.04/Ubuntu 18.04 based infrastructure and would like to set up and configure firewalld
on hosts. I am going to use an Ansible role for that (I have a Vagrant-based setup to test the Ansible role).
When I run Ansible playbooks a freshly installed firewalld
blocks incoming connections by default although I never specified this explicitly:
[ 2161.574030] FINAL_REJECT: IN=enp0s8 OUT= MAC=08:00:27:f9:00:46:0a:00:27:00:00:00:08:00 SRC=172.16.137.1 DST=172.16.137.182 LEN=60 TOS=0x10 PREC=0x00 TTL=64 ID=36677 DF PROTO=TCP SPT=35098 DPT=455 WINDOW=29200 RES=0x00 SYN URGP=0
[ 4717.718425] FINAL_REJECT: IN=enp0s8 OUT= MAC=08:00:27:f9:00:46:0a:00:27:00:00:00:08:00 SRC=172.16.137.1 DST=172.16.137.182 LEN=60 TOS=0x10 PREC=0x00 TTL=64 ID=55673 DF PROTO=TCP SPT=47624 DPT=456 WINDOW=29200 RES=0x00 SYN URGP=0
[ 4719.682792] FINAL_REJECT: IN=enp0s8 OUT= MAC=08:00:27:f9:00:46:0a:00:27:00:00:00:08:00 SRC=172.16.137.1 DST=172.16.137.182 LEN=60 TOS=0x10 PREC=0x00 TTL=64 ID=60255 DF PROTO=TCP SPT=43836 DPT=457 WINDOW=29200 RES=0x00 SYN URGP=0
[ 4721.358343] FINAL_REJECT: IN=enp0s8 OUT= MAC=08:00:27:f9:00:46:0a:00:27:00:00:00:08:00 SRC=172.16.137.1 DST=172.16.137.182 LEN=60 TOS=0x10 PREC=0x00 TTL=64 ID=42733 DF PROTO=TCP SPT=51850 DPT=458 WINDOW=29200 RES=0x00 SYN URGP=0
Is it possible somehow to start firewalld
in a permissive mode then configure everything and then apply the configuration in one shot?