Description of problem: When an alias from /etc/hosts file is used shell is not able to connect to the API Version-Release number of selected component (if applicable): rhevm-cli-3.5.0.5-1.el6ev.noarch How reproducible: 100% Steps to Reproduce: 1. set a new alias for RHEV-M 2. try to connect via this alias Actual results: Alias="rhevm35" "https://rhevm35:443/ovirt-engine/api" is invalid url format, valid format is http[s]://server:port/path, where path is usually "ovirt-engine/api" or, for older versions of the engine, just "api". Expected results: The system either allow to use the alias or it provide more information about the URL format Additional info: The shell expect FQDN so rhevm35.example.com works. from the code: src/ovirtcli/command/connect.py: def is_valid_url(self, url): if url is None: return False; #self.error(url) regex = re.compile( r'^(?:http)s?://' # http:// or https:// r'(?:(?:[A-Z0-9](?:[A-Z0-9-]{0,61}[A-Z0-9])?\.)+(?:[A-Z]{2,6}\.?|[A-Z0-9-]{2,}\.?)|' # domain... r'localhost|' # localhost... r'\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}|' # ...or ipv4 r'\[?[A-F0-9]*:[A-F0-9:]+\]?)' # ...or ipv6 r'(?::\d+)?' # optional port , re.IGNORECASE) if not regex.search(url): return False
*** This bug has been marked as a duplicate of bug 1186365 ***