Skip to content

Commit

Permalink
Merge "Closes-Bug: #1597936 - Removing all missing roles/ mandatory r…
Browse files Browse the repository at this point in the history
…oles checks in SM"
  • Loading branch information
Zuul authored and opencontrail-ci-admin committed Sep 6, 2016
2 parents 391eb84 + 42fa6eb commit ff00d7f
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions src/server_mgr_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -925,18 +925,6 @@ def _validate_roles(self, cluster_id):

cluster_unique_roles = set(cluster_role_list)

missing_roles = roles_set.difference(cluster_unique_roles)
if len(missing_roles) == 1 and next(iter(missing_roles)) == "openstack":
# Check for other mandatory params if Openstack is not configured
self.validate_non_openstack_cluster(cluster_id)
elif len(missing_roles) > 1 and len(cluster_unique_roles) == 1 and next(iter(cluster_unique_roles)) == "openstack":
# Check for other mandatory params if only Openstack role in cluster
self.validate_openstack_only_cluster(cluster_id)
elif len(missing_roles):
msg = "Mandatory roles \"%s\" are not present" % \
", ".join(str(e) for e in missing_roles)
self.log_and_raise_exception(msg)

unknown_roles = cluster_unique_roles.difference(roles_set)
unknown_roles.difference_update(optional_role_set)

Expand Down

0 comments on commit ff00d7f

Please sign in to comment.