updated zabbix state
This commit is contained in:
parent
9903011ba9
commit
3848346b56
@ -1,41 +1,33 @@
|
||||
---
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
zabbix_config_dir:
|
||||
zabbix-config-dir:
|
||||
file.directory:
|
||||
- name: /etc/zabbix
|
||||
- user: {{ zabbix.agent.user }}
|
||||
- group: {{ zabbix.agent.user }}
|
||||
- mode: 755
|
||||
- watch_in:
|
||||
- service: zabbix_agent_service
|
||||
- service: zabbix-agent-service
|
||||
|
||||
zabbix_log_dir:
|
||||
zabbix-log-dir:
|
||||
file.directory:
|
||||
- name: /var/log/zabbix
|
||||
- user: {{ zabbix.agent.user }}
|
||||
- group: {{ zabbix.agent.user }}
|
||||
- mode: 755
|
||||
- watch_in:
|
||||
- service: zabbix_agent_service
|
||||
- service: zabbix-agent-service
|
||||
|
||||
zabbix_agentd_config_dir:
|
||||
zabbix-agent-config-dir:
|
||||
file.directory:
|
||||
- name: /etc/zabbix/zabbix_agentd.conf.d
|
||||
- user: {{ zabbix.agent.user }}
|
||||
- group: {{ zabbix.agent.user }}
|
||||
- mode: 755
|
||||
- watch_in:
|
||||
- service: zabbix_agent_service
|
||||
- service: zabbix-agent-service
|
||||
|
||||
zabbix_agentd_d_dir:
|
||||
file.directory:
|
||||
- name: /etc/zabbix/zabbix_agentd.d
|
||||
- user: {{ zabbix.agent.user }}
|
||||
- group: {{ zabbix.agent.user }}
|
||||
- watch_in:
|
||||
- service: zabbix_agent_service
|
||||
|
||||
zabbix_agent_config:
|
||||
zabbix-agent-config:
|
||||
file.managed:
|
||||
- name: /etc/zabbix/zabbix_agentd.conf
|
||||
- user: {{ zabbix.agent.user }}
|
||||
@ -43,10 +35,10 @@ zabbix_agent_config:
|
||||
- source: salt://zabbix/templates/zabbix_agentd.conf.j2
|
||||
- template: jinja
|
||||
- watch_in:
|
||||
- service: zabbix_agent_service
|
||||
- service: zabbix-agent-service
|
||||
|
||||
{% if zabbix.agent.config.TLSPSKFile is iterable %}
|
||||
zabbix_agent_tlspsk_file:
|
||||
zabbix-agent-tlspsk-file:
|
||||
file.managed:
|
||||
- name: {{ zabbix.agent.config.TLSPSKFile }}
|
||||
- user: {{ zabbix.agent.user }}
|
||||
@ -54,10 +46,10 @@ zabbix_agent_tlspsk_file:
|
||||
- contents: {{ zabbix.agent.psk }}
|
||||
- create: true
|
||||
- watch_in:
|
||||
- service: zabbix_agent_service
|
||||
- service: zabbix-agent-service
|
||||
{% endif %}
|
||||
|
||||
zabbix_userparameters:
|
||||
zabbix-userparameters:
|
||||
file.managed:
|
||||
- name: /etc/zabbix/zabbix_agentd.conf.d/user_parameters.conf
|
||||
- source: salt://zabbix/templates/user_parameters.j2
|
||||
@ -66,4 +58,4 @@ zabbix_userparameters:
|
||||
- mode: 0755
|
||||
- template: jinja
|
||||
- watch_in:
|
||||
- service: zabbix_agent_service
|
||||
- service: zabbix-agent-service
|
||||
|
@ -1,5 +1,5 @@
|
||||
---
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
zabbix_agent_pkgs:
|
||||
zabbix-agent-pkgs:
|
||||
pkg.latest:
|
||||
- pkgs: {{ zabbix.agent.pkgs }}
|
||||
|
@ -1,17 +1,17 @@
|
||||
---
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
zabbix_script_dir:
|
||||
zabbix-script-dir:
|
||||
file.directory:
|
||||
- name: /etc/zabbix/scripts
|
||||
- user: {{ zabbix.agent.user }}
|
||||
- group: {{ zabbix.agent.group }}
|
||||
|
||||
{%- for key, value in zabbix.agent.scripts.items() %}
|
||||
zabbix_script_{{ key }}:
|
||||
{% for key, value in zabbix.agent.scripts.items() -%}
|
||||
zabbix-script-{{ key }}:
|
||||
file.managed:
|
||||
- name: /etc/zabbix/scripts/{{ value.name }}
|
||||
- source: salt://zabbix/scripts/{{ value.name }}
|
||||
- user: {{ zabbix.agent.user }}
|
||||
- group: {{ zabbix.agent.group }}
|
||||
- mode: 0755
|
||||
{%- endfor %}
|
||||
{% endfor -%}
|
||||
|
@ -1,6 +1,6 @@
|
||||
---
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
zabbix_agent_service:
|
||||
zabbix-agent-service:
|
||||
service.running:
|
||||
- name: zabbix-agent
|
||||
- enable: true
|
||||
|
@ -1,6 +1,6 @@
|
||||
---
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
zabbix_server_config:
|
||||
zabbix-server-config:
|
||||
file.managed:
|
||||
- name: /etc/zabbix/zabbix_server.conf
|
||||
- source: salt://zabbix/templates/zabbix_server.conf.j2
|
||||
|
@ -1,7 +1,7 @@
|
||||
---
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
zabbix_server_pkgs:
|
||||
zabbix-server-pkgs:
|
||||
pkg.latest:
|
||||
- pkgs: {{ zabbix.server.pkgs }}
|
||||
- watch_in:
|
||||
- service: zabbix_server_service
|
||||
- service: zabbix-server-service
|
||||
|
@ -1,6 +1,6 @@
|
||||
---
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
zabbix_server_service:
|
||||
zabbix-server-service:
|
||||
service.running:
|
||||
- name: zabbix-server
|
||||
- enable: true
|
||||
|
@ -1,4 +1,4 @@
|
||||
{%- from "zabbix/map.jinja" import zabbix with context -%}
|
||||
{%- for userparameter in zabbix.agent.userparameters %}
|
||||
UserParameter={{ userparameter }}
|
||||
{%- endfor %}
|
||||
{%- endfor %}
|
@ -1,4 +1,4 @@
|
||||
{%- from "zabbix/map.jinja" import zabbix with context -%}
|
||||
{%- for key, value in zabbix.agent.config.items() %}
|
||||
{{ key }}={{ value }}
|
||||
{%- endfor %}
|
||||
{%- endfor %}
|
@ -1,4 +1,4 @@
|
||||
{%- from "zabbix/map.jinja" import zabbix with context %}
|
||||
{%- for key, value in zabbix.server.config.items() %}
|
||||
{{ key }}={{ value }}
|
||||
{%- endfor %}
|
||||
{%- endfor %}
|
Loading…
Reference in New Issue
Block a user