Allow cluster-config on cluster status 'ROLLBACK_COMPLETE'

When cluster is updated with --rollback and cluster update
fails the cluster state changes to 'ROLLBACK_COMPLETE'.
We should allow cluster-config to work on 'ROLLBACK_COMPLETE'
state as well.

Change-Id: Iada1aa5451374b881085a3447af6ce6d0cabada6
Closes-Bug: #1652560
This commit is contained in:
yatinkarel 2016-12-26 09:53:14 +05:30
parent 47b4c9de59
commit afa2281424
1 changed files with 2 additions and 1 deletions

View File

@ -235,7 +235,8 @@ def do_cluster_config(cs, args):
"""
args.dir = os.path.abspath(args.dir)
cluster = cs.clusters.get(args.cluster)
if cluster.status not in ('CREATE_COMPLETE', 'UPDATE_COMPLETE'):
if cluster.status not in ('CREATE_COMPLETE', 'UPDATE_COMPLETE',
'ROLLBACK_COMPLETE'):
raise exceptions.CommandError("cluster in status %s" % cluster.status)
cluster_template = cs.cluster_templates.get(cluster.cluster_template_id)
opts = {