Description of problem:
Per summary, embedded ansible will not start if the hostname of the appliance has an underscore. (or otherwise fails an apparently buggy regexp.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. set hostname to something like "cf_lab1"
2. Attempt to start embedded ansible role
3. See failures in log.
I tried with both "cf_lab1" and "cf_lab1.fake", which failed. "cflab1.fake" worked.
[----] I, [2018-04-23T17:42:45.722835 #16502:57f40cc] INFO -- : MIQ(EmbeddedAnsibleWorker::Runner#setup_ansible) Finished starting embedded ansible service.
[----] E, [2018-04-23T17:42:45.734370 #16502:57f40cc] ERROR -- : [URI::InvalidComponentError]: bad component(expected host component): cf_lab1.fake Method:[block in method_missing]
[----] E, [2018-04-23T17:42:45.734501 #16502:57f40cc] ERROR -- : /opt/rh/rh-ruby23/root/usr/share/ruby/uri/generic.rb:595:in `check_host'
/var/www/miq/vmdb/app/models/embedded_ansible_worker.rb:20:in `block in start_monitor_thread'
[----] I, [2018-04-23T17:42:46.052168 #16898:d99108] INFO -- : MIQ(MiqReportingWorker#log_status) [Reporting Worker] Worker ID , PID , GUID [3615f9f1-2680-47ea-aeb5-0
https://github.com/rest-client/rest-client/issues/556 may be the problem (and have a workaroud)
The issue is that underscore is not allowed in the hostname of a URI. Hostnames can include alphanumeric characters and hyphen. I already added a workaround for this issue in https://github.com/ManageIQ/manageiq/pull/16913 and https://bugzilla.redhat.com/show_bug.cgi?id=1537566
From RFC 3986 section 3.2.2:
A registered name intended for lookup in the DNS uses the syntax defined in Section 3.5 of [RFC1034] and Section 2.1 of [RFC1123]. Such a name consists of a sequence of domain labels separated by ".", each domain label starting and ending with an alphanumeric character and possibly also containing "-" characters.
*** This bug has been marked as a duplicate of bug 1537566 ***