43 lines
1000 B
YAML
43 lines
1000 B
YAML
- name: Intallation paquet zabbix agent
|
|
get_url:
|
|
url: "{{ UrlAgent }}"
|
|
dest: "/tmp"
|
|
|
|
- name: Intallation paquet zabbix agent suite
|
|
apt:
|
|
deb: "{{ PathAgent }}"
|
|
state: present
|
|
|
|
- name: Update apt
|
|
apt:
|
|
update_cache: yes
|
|
|
|
- name: Intallation Zabbix agent
|
|
apt:
|
|
name: zabbix-agent
|
|
state: present
|
|
|
|
- name: Enable Zabbix agent service
|
|
systemd:
|
|
name: zabbix-agent
|
|
state: restarted
|
|
enabled: yes
|
|
|
|
- name: Rm package
|
|
file:
|
|
path: "{{ PathAgent }}"
|
|
state: absent
|
|
|
|
- name: config
|
|
template:
|
|
src: zabbix_agentd.conf.temp
|
|
dest: /etc/zabbix/zabbix_agentd.conf
|
|
vars:
|
|
PidFile: "{{ PidFile }}"
|
|
LogFile: "{{ LogFile }}"
|
|
LogFileSize: "{{ LogFileSize }}"
|
|
Server: "{{ Server }}"
|
|
ServerActive: "{{ ServerActive }}"
|
|
Hostname: "{{ ansible_hostname }}"
|
|
Include: "{{ Include }}"
|