Skip to content
Snippets Groups Projects
Commit f1123e71 authored by cody burkard's avatar cody burkard
Browse files

update interface IP address with pexec so that backgrounded process output...

update interface IP address with pexec so that backgrounded process output from the cli cannot interfere
parent ded25a9e
No related branches found
No related tags found
No related merge requests found
......@@ -86,7 +86,9 @@ def setMAC( self, macstr ):
def updateIP( self ):
"Return updated IP address based on ifconfig"
ifconfig = self.ifconfig()
# use pexec instead of node.cmd so that we dont read
# backgrounded output from the cli.
ifconfig, _err, _exitCode = self.node.pexec( 'ifconfig %s' % self.name )
ips = self._ipMatchRegex.findall( ifconfig )
self.ip = ips[ 0 ] if ips else None
return self.ip
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment