Add check for hostname in migrate_hosts() function

Will raise an error if no hostname provided in cli for 'hosts'
resource type.