Skip to content

Commit

Permalink
Closes-Bug: #1537291
Browse files Browse the repository at this point in the history
    Old contrail code expects the sequencing parameters to be set
    using old params structure, i.e. contrail::params::enable_....
    This is determined based on how initially the sequencing params
    are set.

Change-Id: I391e391c29cfb4d893237573443bf0c828762cb9
  • Loading branch information
ajoshi9 committed Jan 26, 2016
1 parent 50a1391 commit 3797d30
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/server_mgr_puppet.py
Expand Up @@ -774,13 +774,11 @@ def modify_server_hiera_data(self, server_id, hiera_file, role_steps_list,
self._smgr_log.log(self._smgr_log.DEBUG, "role-tuple: %s = %s" % (role_step_tuple[0], role_step_tuple[1]))
if server_id == role_step_tuple[0]:
role_step = role_step_tuple[1].replace('-', '_')
key = 'contrail::params::enable_' + role_step
key = 'contrail::sequencing::enable_' + role_step
if key not in hiera_data_dict:
key = 'contrail::params::enable_' + role_step
self._smgr_log.log(self._smgr_log.DEBUG, "role-key: %s %s" % (key, enable))
if enable:
hiera_data_dict[key] = True
else:
hiera_data_dict[key] = False
hiera_data_dict[key] = enable
data = yaml.dump(hiera_data_dict, default_style='\'', indent=4)
with open(hiera_file, "w") as hiera_fh:
hiera_fh.write(data)
Expand Down

0 comments on commit 3797d30

Please sign in to comment.