mirror of
https://gitlab.sectorq.eu/jaydee/ansible.git
synced 2025-01-23 12:38:11 +00:00
Compare commits
4 Commits
5ec4037fa3
...
0f72226de7
Author | SHA1 | Date | |
---|---|---|---|
|
0f72226de7 | ||
|
d128269757 | ||
|
953bff736d | ||
|
add7afa00b |
@ -13,3 +13,5 @@
|
||||
tags: autofs_client
|
||||
- role: ldap_client
|
||||
tags: ldap_client
|
||||
- role: wazuh-agent
|
||||
tags: wazuh-agent
|
@ -33,3 +33,6 @@
|
||||
name: ssh.service
|
||||
state: restarted
|
||||
become: true
|
||||
|
||||
|
||||
|
19
roles/wazuh-agent/tasks/main.yml
Executable file
19
roles/wazuh-agent/tasks/main.yml
Executable file
@ -0,0 +1,19 @@
|
||||
- block:
|
||||
- name: Get keys
|
||||
ansible.builtin.shell: curl -s https://packages.wazuh.com/key/GPG-KEY-WAZUH | gpg --no-default-keyring --keyring gnupg-ring:/usr/share/keyrings/wazuh.gpg --import && chmod 644 /usr/share/keyrings/wazuh.gpg
|
||||
|
||||
- name: Add repo
|
||||
ansible.builtin.shell: echo "deb [signed-by=/usr/share/keyrings/wazuh.gpg] https://packages.wazuh.com/4.x/apt/ stable main" | tee -a /etc/apt/sources.list.d/wazuh.list
|
||||
- name: Install docker
|
||||
ansible.builtin.apt:
|
||||
update_cache: true
|
||||
- name: Add repo
|
||||
ansible.builtin.shell: WAZUH_MANAGER="192.168.77.101" apt-get install wazuh-agent
|
||||
|
||||
- name: Restart wazuh service
|
||||
ansible.builtin.service:
|
||||
name: wazuh-agent
|
||||
state: restarted
|
||||
enabled: true
|
||||
|
||||
become: true
|
1
roles/wazuh-agent/vars/main.yml
Executable file
1
roles/wazuh-agent/vars/main.yml
Executable file
@ -0,0 +1 @@
|
||||
ZABBIX_SERVER: "zabbix.home.lan"
|
30
servers.yml
30
servers.yml
@ -1,13 +1,23 @@
|
||||
---
|
||||
- hosts: servers
|
||||
roles:
|
||||
- common
|
||||
- wake_on_lan
|
||||
- matter-server
|
||||
- docker
|
||||
- timeshift
|
||||
- monitoring
|
||||
- zabbix-agent
|
||||
- autofs_client
|
||||
- ldap_client
|
||||
- ssh_banner
|
||||
- name: common
|
||||
tags: common
|
||||
- name: wake_on_lan
|
||||
tags: wake_on_lan
|
||||
- name: matter-server
|
||||
tags: matter-server
|
||||
- name: docker
|
||||
tags: docker
|
||||
- name: timeshift
|
||||
tags: timeshift
|
||||
- name: monitoring
|
||||
tags: monitoring
|
||||
- name: zabbix-agent
|
||||
tags: zabbix-agent
|
||||
- name: autofs_client
|
||||
tags: autofs_client
|
||||
- name: ldap_client
|
||||
tags: ldap_client
|
||||
- name: ssh_banner
|
||||
tags: ssh_banner
|
Loading…
x
Reference in New Issue
Block a user