endpoints:
  - name: pve1
    group: proxmox
    url: "icmp://pve1.mydomain.com"
    interval: 60s
    ui:
      resolve-successful-conditions: true
    conditions:
      - "[CONNECTED] == true"

  - name: pve2
    group: proxmox
    url: "icmp://pve2.mydomain.com"
    interval: 60s
    ui:
      resolve-successful-conditions: true
    conditions:
      - "[CONNECTED] == true"

  - name: pve3
    group: proxmox
    url: "icmp://pve3.mydomain.com"
    interval: 60s
    ui:
      resolve-successful-conditions: true
    conditions:
      - "[CONNECTED] == true"

  - name: glances pve1
    group: proxmox
    url: "http://192.168.1.81:61208/api/4/quicklook"
    interval: 120s
    ui:
      resolve-successful-conditions: true
    conditions:
      - "[STATUS] == 200"
      - "[BODY].mem > 0"

  - name: glances pve2
    group: proxmox
    url: "http://192.168.1.82:61208/api/4/quicklook"
    interval: 120s
    ui:
      resolve-successful-conditions: true
    conditions:
      - "[STATUS] == 200"
      - "[BODY].mem > 0"

  - name: glances pve3
    group: proxmox
    url: "http://192.168.1.83:61208/api/4/quicklook"
    interval: 120s
    ui:
      resolve-successful-conditions: true
    conditions:
      - "[STATUS] == 200"
      - "[BODY].mem > 0"

  - name: pve cluster quorum
    group: proxmox
    url: "https://pve.mydomain.com:8006/api2/json/cluster/status"
    interval: 120s
    headers:
      Authorization: "PVEAPIToken=pve-auditor@pam!homepage=${PROXMOX_TOKEN}"
    ui:
      resolve-successful-conditions: true
    conditions:
      - "[STATUS] == 200"
      - "[BODY].data[0].type == cluster"
      - "[BODY].data[0].quorate == 1"
      - "len([BODY].data) == 4"
      - "[CERTIFICATE_EXPIRATION] > 240h"
