Skip to content
Snippets Groups Projects
Commit fcd731d9 authored by Guido Trotter's avatar Guido Trotter
Browse files

Check that the selected instances are known


Signed-off-by: default avatarGuido Trotter <ultrotter@google.com>
Reviewed-by: default avatarIustin Pop <iustin@google.com>
parent c6ccc073
No related branches found
No related tags found
No related merge requests found
......@@ -221,7 +221,10 @@ mergeData um extags selinsts exinsts cdata@(ClusterData _ nl il2 tags) =
in if not $ all (`elem` all_inst_names) exinsts
then Bad $ "Some of the excluded instances are unknown: " ++
show (exinsts \\ all_inst_names)
else Ok cdata { cdNodes = snl, cdInstances = sil }
else if not $ all (`elem` all_inst_names) selinsts
then Bad $ "Some of the selected instances are unknown: " ++
show (selinsts \\ all_inst_names)
else Ok cdata { cdNodes = snl, cdInstances = sil }
-- | Checks the cluster data for consistency.
checkData :: Node.List -> Instance.List
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment