Use Case : generate YAML based on Existing Windows Services


I have a use case and wish to check if and how I can achieve the following scenario.

I have several servers, where we have

  • a different set of Windows Services
  • several web application

I need to create a YAML file for the DataDog agent. This one should:

  • Contains a list of the windows services started on the server.
  • For each window service, I need to add the path to the log files. Each service has a config file in its folder. This config file contains the path to the log file.

What approach should I apply?