Is there any way to loop over an array when using token substitution? I’ve tried the obvious, but no dice.
For example, if I had a client that had children: [ ‘child-a’, ‘child-b’], I’d like to be able to use :::children.hosts::: in a check named ‘check-children’. This way, each client can be responsible for its children (This is just an example, it could be NICs, services, etc.) and I can contain all of the templating for the checks in the client.json and manage with config management.
I realise this is very close to becoming over-complicated, but this doesn’t seem like too much of a stretch? Alternatively, can the new proxy check features help me achieve this? I know there has been some progress towards generating checks based on client attributes.
If there’s another way to achieve this - or if I’m approaching this all wrong - I’m all ears!