fail2ban/application: Moved vars to global part

Because paths are not user-configured but given by package/system
dehydrated
Felix Stupp 5 years ago
parent 66e38ebcde
commit 239ef3124e
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -85,6 +85,12 @@ global_dns_upstream_servers:
global_dnsmasq_configuration_file: "/etc/dnsmasq.conf"
global_dnsmasq_configuration_directory: "/etc/dnsmasq.d"
global_fail2ban_system_directory: "/etc/fail2ban"
global_fail2ban_configuration_directory: "{{ global_fail2ban_system_directory }}/fail2ban.d"
global_fail2ban_actions_directory: "{{ global_fail2ban_system_directory }}/action.d"
global_fail2ban_filters_directory: "{{ global_fail2ban_system_directory }}/filter.d"
global_fail2ban_jails_directory: "{{ global_fail2ban_system_directory }}/jail.d"
global_ip_discover_url: "https://keys.banananet.work/ping"
global_ip_discover_register_pass: "{{ lookup('password', 'credentials/ip_discover/register_pass chars=digits,ascii_letters length=256') }}"

@ -1,7 +0,0 @@
---
config_dir: "/etc/fail2ban"
configuration_directory: "{{ config_dir }}/fail2ban.d"
actions_directory: "{{ config_dir }}/action.d"
filters_directory: "{{ config_dir }}/filter.d"
jails_directory: "{{ config_dir }}/jail.d"

@ -14,7 +14,7 @@
- name: Configure fail2ban
template:
src: fail2ban.conf
dest: "{{ configuration_directory }}/0_main.local"
dest: "{{ global_fail2ban_configuration_directory }}/0_main.local"
owner: root
group: root
mode: u=rw,g=r,o=r
@ -23,7 +23,7 @@
- name: Configure sshd jail
template:
src: sshd.jail.conf
dest: "{{ jails_directory }}/sshd.local"
dest: "{{ global_fail2ban_jails_directory }}/sshd.local"
owner: root
group: root
mode: u=rw,g=r,o=r

Loading…
Cancel
Save