Description of problem: In CFME UI, Migration settings, it is possible to add an existing RHV host, as a conversion host. However, once a RHV host is picked as a conversion host, it is not possible to pick it anymore, to create additional conversion hosts. Using rest api, it is possible to create multiple conversion hosts, for the same single RHV host Version-Release number of selected component (if applicable): CFME-5.10.6.1 RHV-4.3.4.3 Expected: api request to create a conversion host, based on a RHV host, in case there such already should fail.
Ok, I think the best approach is to check the tags to see if a resource is already set as a conversion host.
Changed it to a model validation: https://github.com/ManageIQ/manageiq/pull/18959
{ "name": "env-rhv43-01.cfme2.lab.eng.rdu2.redhat.com", "resource_type": "ManageIQ::Providers::Redhat::InfraManager::Host", "resource_id": "1", "conversion_host_ssh_private_key": "Bag Attributes\n ..\n", "vmware_vddk_package_url": "http://file.rdu.redhat.com/~ytale/VMware-vix-disklib-6.5.2-6195444.x86_64.tar.gz", "auth_user": "root" } Getting { "error":{ "kind": "bad_request", "message": "unsupported resource_type ManageIQ::Providers::Redhat::InfraManager::Host", "klass": "Api::BadRequestError" } }
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2019:4199