nmollerup
11/13/2024, 2:51 PMfirewall { '842 LOG-AND-ACCEPT':
chain => 'LOG-AND-ACCEPT',
jump => 'accept',
proto => 'all',
}
no corrective changes in a puppet run, if I delete the created rule:
iptables -D LOG-AND-ACCEPT -m comment --comment "842 LOG-AND-ACCEPT" -j ACCEPT
puppet run
Notice: /Stage[main]/Profile::Firewall::Base/Firewall[842 LOG-AND-ACCEPT]/ensure: defined 'ensure' as 'present' (corrective)
Notice: firewall[842 LOG-AND-ACCEPT]: Creating: Creating Rule '842 LOG-AND-ACCEPT' with {:name=>"842 LOG-AND-ACCEPT", :chain=>"LOG-AND-ACCEPT", :proto=>"all", :jump=>"ACCEPT", :ensure=>"present", :protocol=>"IPv4", :table=>"filter"}
Error: firewall[842 LOG-AND-ACCEPT]: Creating: Failed after 0.011915 seconds: undefined method `[]' for nil:NilClass
Error: /Stage[main]/Profile::Firewall::Base/Firewall[842 LOG-AND-ACCEPT]: Could not evaluate: Execution encountered an error
adding rule manually with
iptables -A LOG-AND-ACCEPT -m comment --comment "842 LOG-AND-ACCEPT" -j ACCEPT
works and puppet changes nothing after that