set NODE_NAME and NODE_NUMBER in default vnoded environment for SimpleLxcNodes
(Boeing r1788)
This commit is contained in:
parent
b6f4e035c2
commit
102dd2aa3b
1 changed files with 5 additions and 2 deletions
|
@ -55,9 +55,12 @@ class SimpleLxcNode(PyCoreNode):
|
|||
"-p", self.ctrlchnlname + ".pid"]
|
||||
if self.nodedir:
|
||||
vnoded += ["-C", self.nodedir]
|
||||
env = self.session.getenviron(state=False)
|
||||
env['NODE_NUMBER'] = str(self.objid)
|
||||
env['NODE_NAME'] = str(self.name)
|
||||
|
||||
try:
|
||||
tmp = subprocess.Popen(vnoded, stdout = subprocess.PIPE,
|
||||
env = self.session.getenviron(state=False))
|
||||
tmp = subprocess.Popen(vnoded, stdout = subprocess.PIPE, env = env)
|
||||
except OSError, e:
|
||||
msg = "error running vnoded command: %s (%s)" % (vnoded, e)
|
||||
self.exception(coreapi.CORE_EXCP_LEVEL_FATAL,
|
||||
|
|
Loading…
Reference in a new issue