[crowdsec] feat: moved crowdsec to its own role
This commit is contained in:
parent
d664909fdf
commit
6c810044fb
3 changed files with 0 additions and 63 deletions
|
|
@ -11,7 +11,6 @@ This role manages the build-in 'core' Operating System components and defaults t
|
|||
# Tags
|
||||
- apt
|
||||
- cron
|
||||
- crowdsec
|
||||
- environment-file
|
||||
- hostname
|
||||
- firewall
|
||||
|
|
|
|||
|
|
@ -1,52 +0,0 @@
|
|||
---
|
||||
|
||||
# install crowdsec signing key
|
||||
- name: "install signing key"
|
||||
ansible.builtin.get_url:
|
||||
url: "https://packagecloud.io/crowdsec/crowdsec/gpgkey"
|
||||
dest: "/etc/apt/keyrings/crowdsec_crowdsec-archive-keyring.gpg"
|
||||
mode: "0644"
|
||||
register: "install_crowdsec_key"
|
||||
tags:
|
||||
- "crowdsec"
|
||||
|
||||
# update apt cache if required
|
||||
- name: "update apt cache"
|
||||
ansible.builtin.apt:
|
||||
update_cache: true
|
||||
when:
|
||||
- 'ansible_os_family == "Debian"'
|
||||
- "install_crowdsec_key.changed"
|
||||
tags:
|
||||
- "crowdsec"
|
||||
|
||||
# install crowdsec security engine
|
||||
- name: "install crowdsec security engine"
|
||||
ansible.builtin.apt:
|
||||
name: "crowdsec"
|
||||
state: "present"
|
||||
cache_valid_time: "120"
|
||||
when: 'ansible_os_family == "Debian"'
|
||||
register: "crowdsec_installed"
|
||||
tags:
|
||||
- "crowdsec"
|
||||
|
||||
# install crowdsec firewall bouncer - debian
|
||||
- name: "install crowdsec firewall bouncer - debian"
|
||||
ansible.builtin.apt:
|
||||
name: "crowdsec-firewall-bouncer"
|
||||
state: "present"
|
||||
cache_valid_time: "120"
|
||||
when: 'ansible_distribution == "Debian"'
|
||||
tags:
|
||||
- "crowdsec"
|
||||
|
||||
# install crowdsec firewall bouncer - ubuntu
|
||||
- name: "install crowdsec firewall bouncer - ubuntu"
|
||||
ansible.builtin.apt:
|
||||
name: "crowdsec-firewall-bouncer-iptables"
|
||||
state: "present"
|
||||
cache_valid_time: "120"
|
||||
when: 'ansible_distribution == "Ubuntu"'
|
||||
tags:
|
||||
- "crowdsec"
|
||||
|
|
@ -6,7 +6,6 @@
|
|||
tags:
|
||||
- "apt"
|
||||
- "cron"
|
||||
- "crowdsec"
|
||||
- "environment-file"
|
||||
- "hostname"
|
||||
- "firewall"
|
||||
|
|
@ -33,7 +32,6 @@
|
|||
tags:
|
||||
- "apt"
|
||||
- "cron"
|
||||
- "crowdsec"
|
||||
- "environment-file"
|
||||
- "hostname"
|
||||
- "firewall"
|
||||
|
|
@ -271,14 +269,6 @@
|
|||
when: "os_support"
|
||||
tags: "usermanagement"
|
||||
|
||||
# crowdsec
|
||||
- name: "crowdsec security engine"
|
||||
ansible.builtin.include_tasks: "crowdsec.yaml"
|
||||
when:
|
||||
- "os_support"
|
||||
- "crowdsec_enable"
|
||||
tags: "crowdsec"
|
||||
|
||||
# firewall
|
||||
- name: "firewall"
|
||||
ansible.builtin.import_tasks: "firewall/firewall-general.yaml"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue