I want to to retrieve a list of the virtual hosts which are currently loaded and listening for requests i.e not just grepping the config files.
It looks like apache2ctl -S
does this but I am not 100% sure if that is just returning what is contained in the config files.