I can do a curl on a page like this:
curl --user test:test01 -X ‘GET’
‘https://x.x.x.x:/api/files/v3/config/file-s/jhkjhkjhkjhkjhfkjhk/mount-targets?$select=name,CurrentSizeGib&$filter=contains(name,‘work-production’)’
-k -H ‘accept: application/json’
and get some fields and values returned so I know how much space is used on an nfs share. But how do I get something like that in Icinga?
I looked at check_http - this will give me an output on the page but then how to parse out the info I need and then to make it into a service check, example 40GB extracted from the field is checked against 24W/40C thresholds.
I understand this is perhaps a lazy thing to ask but just before I set off and make something way over elaborate is there any easy way to do this with say a plugin I have missed.
Note: do not have access to python 3.