Files
dsfin-ansible/roles/fail2ban/tasks/main.yml
2022-01-19 18:17:44 +00:00

20 lines
457 B
YAML

---
- name: install fail2ban package
apt:
name: fail2ban
state: present
update_cache: yes
when: ansible_distribution=='Debian' or ansible_distribution=='Ubuntu'
become: yes
tags: fail2ban
- name: copy fail2ban local config
copy:
src: "{{ role_path }}/files/jail.local"
dest: /etc/fail2ban/jail.local
owner: root
group: root
mode: 0644
become: yes
tags: fail2ban