Skip to content

Instantly share code, notes, and snippets.

@kszarek
Created June 23, 2014 12:06
Show Gist options
  • Save kszarek/0dc559e897958b78a01b to your computer and use it in GitHub Desktop.
Save kszarek/0dc559e897958b78a01b to your computer and use it in GitHub Desktop.
Create ec2 instance with new ssd backed ebs
dev_sda1 = boto.ec2.blockdevicemapping.BlockDeviceType(
delete_on_termination=True, volume_type='gp2')
dev_sda1.size = env.ebs_size # size in Gigabytes
bdm = boto.ec2.blockdevicemapping.BlockDeviceMapping()
bdm['/dev/sda'] = dev_sda1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment