our ops team wants to make sure that all IIS web sites are (a) logging to the right place and (b) logging the right things. The most awesome IIS Cookbook allows me to do both of these things if I know what sites are running on this old box, which, sadly, I do not. So a fairly straightforward implementation could be:
list_of_sites.each do |s|
iis_site s do
log_directory 'c:/fireplace'
etc.
end
end
But ... I don't know what sites are running on a given node. Ohai doesn't seem to have this info, but maybe there is a wonderous (I like this spelling better) Ohai plugin that my google-foo couldn't find. I could write an ohai plugin for this I suppose. But it would be my first so a little reluctant to go there. Are there other options?
Good list of ways to list sites is here: Display all sites and bindings in powershell, but not sure how to use a list of sites generated by powershell from within a recipe.
We're running chef 12 and various IIS's but oldest is 7.0.
Thx for any advice!