Yoav Kleinberger has posted comments on this change.
Change subject: tests: use 'localhost' explicitly in test
Patch Set 1:
Line 79: isSSL = config.getboolean('vars', 'ssl')
Line 80: if isSSL and os.geteuid() != 0:
Line 81: raise SkipTest("Must be root to use SSL connection to
Line 82: address = 'localhost:%s' % config.get('addresses',
Line 83: self.s = vdscli.connect(hostPort=address, useSSL=isSSL)
Please explain what fails on your host, and what is different in this
I investigated the failure and this is what I found:
vdscli.py gets the hostname by parsing the ssl certificate on the machine you run it on.
usually, this name is resolvable into an IP by all relevant machines. On my development
environment, this name is not defined in our local DNS (I use /etc/hosts on my other
machines to access it). This is why it fails. You can blame my improper configuration, but
please read on before deciding.
Since vdscli clearly assumes that it is running on the very machine that it will later try
to communicate with (it accesses /etc/pki/vdsm) - this is totally unneeded and overly
implicit. BTW, the SSL verification is lacking, since I can, in fact, connect using SSL to
'localhost', but that is another issue.
However, I don't need to fix vdscli.py. I can totally avoid this implicit stuff by
'localhost', which makes the test explicit and more readable.
So I'm still in favor of this change.
Line 85: def assertVdsOK(self, vdsResult):
Line 86: # code == 0 means OK
Line 87: self.assertEquals(
To view, visit http://gerrit.ovirt.org/28107
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-Owner: Yoav Kleinberger <ykleinbe(a)redhat.com>
Gerrit-Reviewer: Adam Litke <alitke(a)redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce(a)redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Vered Volansky <vvolansk(a)redhat.com>
Gerrit-Reviewer: Yoav Kleinberger <ykleinbe(a)redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server