community / community.general / 0.1.1 / module / zabbix_service Create/update/delete Zabbix service Authors: Emmanuel Riviere (@emriver) preview | supported by communitycommunity.general.zabbix_service (0.1.1) — module
Install with ansible-galaxy collection install community.general:==0.1.1
collections: - name: community.general version: 0.1.1
Create/update/delete Zabbix service.
--- # Creates a new Zabbix service - name: Manage services local_action: module: zabbix_service server_url: "https://192.168.1.1" login_user: username login_password: password name: apache2 service sla: 99.99 calculate_sla: yes algorithm: one_child trigger_name: apache2 service status trigger_host: webserver01 state: present
sla: description: - Sla value (i.e 99.99), goodsla in Zabbix API required: false type: float name: description: - Name of Zabbix service required: true type: str state: choices: - present - absent default: present description: - 'State: present - create/update service; absent - delete service' required: false type: str parent: description: - Name of Zabbix service parent required: false type: str timeout: default: 10 description: - The timeout of API request (seconds). type: int algorithm: choices: - 'no' - one_child - all_children default: one_child description: - Algorithm used to calculate the sla - C(no), sla is not calculated - C(one_child), problem if at least one child has a problem - C(all_children), problem if all children have problems required: false type: str login_user: description: - Zabbix user name. required: true type: str server_url: aliases: - url description: - URL of Zabbix server, with protocol (http or https). C(url) is an alias for C(server_url). required: true type: str trigger_host: description: - Name of host linked to the service required: false type: str trigger_name: description: - Name of trigger linked to the service required: false type: str calculate_sla: description: - If yes, calculate the SLA value for this service, showsla in Zabbix API required: false type: bool login_password: description: - Zabbix user password. required: true type: str validate_certs: default: true description: - If set to False, SSL certificates will not be validated. This should only be used on personally controlled sites using self-signed certificates. type: bool http_login_user: description: - Basic Auth login type: str http_login_password: description: - Basic Auth password type: str