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.

Used Faraday as I just wanted to fetch the head. Guess I can switch to
```ruby
ProxyAPI::Features.new({:url => smart_proxy.url}).features
```