From 4a14f9c2724b894a1b218fb7ad0f7c81a52c8855 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Fri, 21 Feb 2020 10:57:16 -0600 Subject: [PATCH] mgr/orch: remove label: prefix when parsing placementspec Signed-off-by: Sage Weil --- src/pybind/mgr/orchestrator/_interface.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pybind/mgr/orchestrator/_interface.py b/src/pybind/mgr/orchestrator/_interface.py index 59fa605f85c33..30347796973b1 100644 --- a/src/pybind/mgr/orchestrator/_interface.py +++ b/src/pybind/mgr/orchestrator/_interface.py @@ -1246,7 +1246,7 @@ class PlacementSpec(object): strings.remove('all:true') hosts = [x for x in strings if x != '*' and 'label:' not in x] - labels = [x for x in strings if 'label:' in x] + labels = [x[6:] for x in strings if 'label:' in x] if len(labels) > 1: raise OrchestratorValidationError('more than one label provided: {}'.format(labels)) -- 2.39.5