usr/lib/observium_agent/scripts-available/proxmox-qemu hinzugefügt

Ursprüngliche Version des Skriptes
This commit is contained in:
ageissler
2024-12-30 17:53:11 +01:00
parent 6a45664a65
commit 3b4d130428

View File

@@ -0,0 +1,18 @@
#!/bin/bash
# Proxmox VE virtual machine listing
# (c) 2015-2019, Tom Laermans for Observium
PVESH=`which pvesh`
if [ $? -eq 0 ]
then
echo "<<<proxmox-qemu>>>"
VERSION=$(pveversion | awk -F/ '{print $2}' | sed 's/\..*//')
if [[ ${VERSION} -ge 5 ]]
then
pvesh get /nodes/$(hostname)/qemu --output-format=json-pretty 2>/dev/null
else
pvesh get /nodes/$(hostname)/qemu 2>/dev/null
fi
fi