You've already forked role_fail2ban
[INFO] Créer le dépôt
This commit is contained in:
69
README.md
69
README.md
@@ -1,3 +1,68 @@
|
||||
# role_modele
|
||||
# role_fail2ban
|
||||
|
||||
Modèle
|
||||
Ce rôle permet d'installation, configurer et supprimer la configuration de fail2ban.
|
||||
|
||||
## Variables
|
||||
|
||||
### fail2ban_destemail
|
||||
|
||||
Adresse IP où seront envoyé les alertes.
|
||||
|
||||
*<span style="text-decoration: underline">Valeur par défaut:</span> aucune*
|
||||
|
||||
### fail2ban_ignoreip
|
||||
|
||||
Liste d'adresse IP qui seront ignorées et donc jamais bannis.
|
||||
|
||||
*<span style="text-decoration: underline">Valeur par défaut:</span> aucune*
|
||||
|
||||
### fail2ban_ssh_port
|
||||
|
||||
Port d'écoute de SSH.
|
||||
|
||||
*<span style="text-decoration: underline">Valeur par défaut:</span> aucune*
|
||||
|
||||
### fail2ban_templates_*
|
||||
|
||||
Liste de templates à déployer.
|
||||
|
||||
*<span style="text-decoration: underline">Valeur par défaut:</span> aucune*
|
||||
|
||||
## Exemple d'utilisation
|
||||
|
||||
### inventory.yml
|
||||
|
||||
```yaml
|
||||
---
|
||||
|
||||
all:
|
||||
hosts:
|
||||
host1.ykn.local:
|
||||
host2.ykn.local:
|
||||
children:
|
||||
dnsservers:
|
||||
hosts:
|
||||
dnsmasq1.ykn.local:
|
||||
dnsmasq2.ykn.local:
|
||||
```
|
||||
|
||||
### group_vars/all.yml
|
||||
|
||||
```yaml
|
||||
---
|
||||
|
||||
fail2ban_destemail: hostmaster@ykn.local
|
||||
fail2ban_sender: "{{ inventory_hostname }} <fail2ban@ykn.local>"
|
||||
fail2ban_ignoreip: []
|
||||
fail2ban_ssh_port: 22
|
||||
```
|
||||
|
||||
### playbook.yml
|
||||
|
||||
```yaml
|
||||
---
|
||||
|
||||
- hosts: 'all'
|
||||
roles:
|
||||
- name: fail2ban
|
||||
```
|
||||
|
Reference in New Issue
Block a user