Synthetic Monitoring Private Locations per Agent

Hi,
We have several fleet policies with with large numbers of agents. Now, we want to run some synthetic monitors on these agents, problem is that the monitor would look different on each host (different url to call, different certificate, ...), so we can't really say "execute this monitor on all hosts in this policy/private location". It would be a huge change for the better if we would somehow be able to have more control over monitors-locations-policies. I see a few possible solutions:

  • If we'd be able to define locations on an agent-level instead of the policy level, this would fix the problem.
  • If we'd be able to use one location/policy but have the ability to add a condition to only execute the monitor if the agent has name X or has tag Y, then we'd also be able to fix this by creating a monitor for each agent.
  • Ultimate solution: It would be pretty awesome if we could define variables/parameters on the fleet policy level and on the agent level. Then the monitor could be built generically and just pickup its agent-specific values from the variables/parameters.

Hi,

Did you already try to use params or environment variables?

We have the agent running as a container, so we set the agent specific data as an Openshift Secret which is then provided as an environment variable.

If you are creating and managing synthetic monitors using a Synthetics project, you can also use regular environment variables via the standard node process.env global object.

Best regards
Wolfram

1 Like

Nice! I didn't know we could access the local environment.