fix more casing errors and make attachment set print

This commit is contained in:
Vishvananda Ishaya
2010-06-24 04:11:57 +01:00
committed by andy
parent 79549993f6
commit e3b6e0537e
2 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -262,7 +262,7 @@ class CloudController(object):
volume.get('node_name', None),
volume.get('instance_id', ''),
volume.get('mountpoint', ''))
if volume['status'] == 'attached':
if volume['attach_status'] == 'attached':
v['attachmentSet'] = [{'attachTime': volume['attach_time'],
'deleteOnTermination': volume['delete_on_termination'],
'device' : volume['mountpoint'],
+3 -3
View File
@@ -165,11 +165,11 @@ class Volume(datastore.RedisModel):
vol['availability_zone'] = FLAGS.storage_availability_zone
vol["instance_id"] = 'none'
vol["mountpoint"] = 'none'
vol['attachTime'] = 'none'
vol['attach_time'] = 'none'
vol["create_time"] = time.strftime('%Y-%m-%dT%H:%M:%SZ', time.gmtime())
vol['status'] = "creating" # creating | available | in-use
vol['attachStatus'] = "detached" # attaching | attached | detaching | detached
vol['deleteOnTermination'] = 'False'
vol['attach_status'] = "detached" # attaching | attached | detaching | detached
vol['delete_on_termination'] = 'False'
vol.save()
vol.create_lv()
vol.setup_export()