This commit is contained in:
2026-02-16 01:51:15 +01:00
parent 1c2831a7ba
commit ef8839d33a

View File

@@ -242,10 +242,32 @@
register: proxygroup_check
- name: Print proxy_check
- name: Print proxygroup_check
debug:
msg: "{{ proxygroup_check }}"
- name: Create proxy if not exists
uri:
url: "{{ zabbix_api_url }}"
method: POST
body_format: json
body:
jsonrpc: "2.0"
method: "proxygroup.create"
params:
name: "{{ clustename }}"
failover_delay: "5m"
min_online: 1
id: 1
headers:
Content-Type: "application/json"
Authorization: "Bearer {{ zabbix_auth_token }}"
when: proxygroup_check.json.result | length == 0
register: proxygroup_check2
- name: Print proxygroup_check2
debug:
msg: "{{ proxygroup_check2 }}"
- name: Check if proxy exists
uri: