Revision 437138c9 lib/mcpu.py
b/lib/mcpu.py | ||
---|---|---|
287 | 287 |
env = self.env.copy() |
288 | 288 |
env["GANETI_HOOKS_PHASE"] = phase |
289 | 289 |
env["GANETI_HOOKS_PATH"] = hpath |
290 |
if self.lu.sstore is not None:
|
|
291 |
env["GANETI_CLUSTER"] = self.lu.sstore.GetClusterName()
|
|
292 |
env["GANETI_MASTER"] = self.lu.sstore.GetMasterNode()
|
|
290 |
if self.lu.cfg is not None:
|
|
291 |
env["GANETI_CLUSTER"] = self.lu.cfg.GetClusterName()
|
|
292 |
env["GANETI_MASTER"] = self.lu.cfg.GetMasterNode()
|
|
293 | 293 |
|
294 | 294 |
env = dict([(str(key), str(val)) for key, val in env.iteritems()]) |
295 | 295 |
|
... | ... | |
340 | 340 |
""" |
341 | 341 |
phase = constants.HOOKS_PHASE_POST |
342 | 342 |
hpath = constants.HOOKS_NAME_CFGUPDATE |
343 |
if self.lu.sstore is None: |
|
344 |
raise errors.ProgrammerError("Null sstore on config update hook") |
|
345 |
nodes = [self.lu.sstore.GetMasterNode()] |
|
343 |
nodes = [self.lu.cfg.GetMasterNode()] |
|
346 | 344 |
results = self._RunWrapper(nodes, hpath, phase) |
Also available in: Unified diff