api/install.go
func installHostList(w http.ResponseWriter, r *http.Request, t auth.Token) error {
	allowed := permission.Check(t, permission.PermInstallManage)
	if !allowed {
		return permission.ErrUnauthorized
	}
	hosts, err := install.ListHosts()
	if err != nil {
		return err
	}
	w.Header().Set("Content-Type", "application/json")
	return json.NewEncoder(w).Encode(&hosts)
}
func installHostList(w http.ResponseWriter, r *http.Request, t auth.Token) error {
	allowed := permission.Check(t, permission.PermInstallManage)
	if !allowed {
		return permission.ErrUnauthorized
	}
	hosts, err := install.ListHosts()
	if err != nil {
		return err
	}
	w.Header().Set("Content-Type", "application/json")
	return json.NewEncoder(w).Encode(&hosts)
}
// title: list install hosts
// path: /install/hosts
// method: GET
// produce: application/json
// responses:
//   200: OK
//   401: Unauthorized