xoxys.iptables/index.md

83 lines
1.9 KiB
Markdown
Raw Normal View History

---
title: iptables
type: docs
---
[![Source Code](https://img.shields.io/badge/gitea-source%20code-blue?logo=gitea&logoColor=white)](https://gitea.rknet.org/ansible/xoxys.logrotate) [![Build Status](https://img.shields.io/drone/build/ansible/xoxys.logrotate?logo=drone&server=https%3A%2F%2Fdrone.rknet.org)](https://drone.rknet.org/ansible/xoxys.logrotate) [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
Role to manage iptables firewall.
* [Default Variables](#default-variables)
* [iptables_app_rules](#iptables-app-rules)
* [iptables_app_rules_extra](#iptables-app-rules-extra)
* [iptables_custom_rules](#iptables-custom-rules)
* [iptables_default_head](#iptables-default-head)
* [iptables_default_tail](#iptables-default-tail)
* [iptables_keep_unmanaged](#iptables-keep-unmanaged)
* [Dependencies](#dependencies)
---
## Default Variables
### iptables_app_rules
#### Default value
```YAML
iptables_app_rules: []
```
### iptables_app_rules_extra
#### Default value
```YAML
iptables_app_rules_extra: []
```
### iptables_custom_rules
#### Default value
```YAML
iptables_custom_rules: []
```
### iptables_default_head
Default head (allow) rules.
#### Default value
```YAML
iptables_default_head: "-P INPUT ACCEPT\n-P FORWARD ACCEPT\n-P OUTPUT ACCEPT\n-A INPUT\
\ -m state --state RELATED,ESTABLISHED -j ACCEPT\n-A INPUT -i lo -j ACCEPT\n-A INPUT\
\ -p icmp --icmp-type echo-request -j ACCEPT\n-A INPUT -p tcp -m tcp --dport 22\
\ -j ACCEPT\n"
```
### iptables_default_tail
Default tail (deny) rules.
#### Default value
```YAML
iptables_default_tail: "-A INPUT -j REJECT\n-A FORWARD -j REJECT\n"
```
### iptables_keep_unmanaged
By default this role deletes all iptables rules which are not managed by Ansible. Set this to 'yes', if you want the role to keep unmanaged rules.
#### Default value
```YAML
iptables_keep_unmanaged: no
```
## Dependencies
None.