Commit b7c7e52b authored by Klaus Aehlig's avatar Klaus Aehlig

Support no-master state in ssconf

When destroying a cluster, it needs to go to no-master state
first, to ensure daemons will refuse to restart. So, even if
there is no master, we need to provide a value the master entry
in ssconf. The value chosen contains a space character and therefore
cannot be a valid domain name.
Signed-off-by: default avatarKlaus Aehlig <aehlig@google.com>
Reviewed-by: default avatarPetr Pudlak <pudlak@google.com>
parent 6f7f3ce5
......@@ -71,7 +71,7 @@ mkSSConf cdata = SSConf $ M.fromList
, (SSMasterNetdev, return $ clusterMasterNetdev cluster)
, (SSMasterNetmask, return . show $ clusterMasterNetmask cluster)
, (SSMasterNode, return
. genericResult (error "Master node not found") nodeName
. genericResult (const "NO MASTER") nodeName
. getNode cdata $ clusterMasterNode cluster)
, (SSNodeList, mapLines nodeName nodes)
, (SSNodePrimaryIps, mapLines (spcPair . (nodeName &&& nodePrimaryIp))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment