Changes as per @abadger

This commit is contained in:
Khushil Dep 2016-09-14 15:01:24 +01:00 committed by Daniel Malon
parent 054e640fba
commit 08db04ccb6
No known key found for this signature in database
GPG key ID: FCB97856BBA5B14D

View file

@ -1326,8 +1326,8 @@ class Ec2Inventory(object):
instance_vars["ec2_security_group_names"] = ','.join([str(i) for i in group_names])
elif key == 'ec2_block_device_mapping':
instance_vars["ec2_block_devices"] = {}
for k, v in value.iteritems():
instance_vars["ec2_block_devices"][ ( k.split( '/' ) )[ -1 ] ] = v.volume_id
for k, v in value.items():
instance_vars["ec2_block_devices"][ os.path.basename(k) ] = v.volume_id
else:
pass
# TODO Product codes if someone finds them useful