Check nodes roles before deployment

Nodes roles should be checked in CheckBeforeDeploymentTask,
because it's possible to deploy node with conflicting roles
or with incompatible role. Roles release metadata will be
used for roles checks, this metadata contains restrictions.

Since `depends` is not used anymore, it's changed to
`restrictions` in assignment validator.

Change-Id: Ibba7951968cbafd59fff0d516e74f9dd9e454edc
Closes-Bug: #1573006
(cherry picked from commit 3482a5d7a9417c268a526cf511e114be94c884be)
This commit is contained in:
Artur Svechnikov 2016-05-04 13:29:17 +03:00 committed by Nikita Zubkov
parent e15ad4ab63
commit 7cf79178e6
1 changed files with 1 additions and 1 deletions

View File

@ -187,7 +187,7 @@ class TestNodeReassignNoReinstallValidator(tests_base.BaseCloneClusterTest):
"reprovision": False,
"roles": ['controller', 'compute'],
})
msg = '^Role "controller" in conflict with role compute$'
msg = "^Role 'controller' in conflict with role 'compute'.$"
with self.assertRaisesRegexp(errors.InvalidData, msg):
self.validator.validate(data, self.dst_cluster)