Fixes #746 - Generate all the Host template when click on Build to avoid...

Generate all the Host template when click on Build to avoid errors during installation.
Includes moving of template_used to Managed model so it can be used elsewhere.

some exceptions can actually happen here, as there are validations that might go to the proxy, and raise an exception if the proxy is not avail.
in the long term, we need to move all of the non db validations out of the object and into this kind of service class imho.