github.com/danp/terraform@v0.9.5-0.20170426144147-39d740081351/website/source/docs/providers/aws/d/ebs_volume.html.markdown (about) 1 --- 2 layout: "aws" 3 page_title: "AWS: aws_ebs_volume" 4 sidebar_current: "docs-aws-datasource-ebs-volume" 5 description: |- 6 Get information on an EBS volume. 7 --- 8 9 # aws\_ebs\_volume 10 11 Use this data source to get information about an EBS volume for use in other 12 resources. 13 14 ## Example Usage 15 16 ```hcl 17 data "aws_ebs_volume" "ebs_volume" { 18 most_recent = true 19 20 filter { 21 name = "volume-type" 22 values = ["gp2"] 23 } 24 25 filter { 26 name = "tag:Name" 27 values = ["Example"] 28 } 29 } 30 ``` 31 32 ## Argument Reference 33 34 The following arguments are supported: 35 36 * `most_recent` - (Optional) If more than one result is returned, use the most 37 recent Volume. 38 * `filter` - (Optional) One or more name/value pairs to filter off of. There are 39 several valid keys, for a full reference, check out 40 [describe-volumes in the AWS CLI reference][1]. 41 42 43 ## Attributes Reference 44 45 The following attributes are exported: 46 47 * `id` - The volume ID (e.g. vol-59fcb34e). 48 * `volume_id` - The volume ID (e.g. vol-59fcb34e). 49 * `availability_zone` - The AZ where the EBS volume exists. 50 * `encrypted` - Whether the disk is encrypted. 51 * `iops` - The amount of IOPS for the disk. 52 * `size` - The size of the drive in GiBs. 53 * `snapshot_id` - The snapshot_id the EBS volume is based off. 54 * `volume_type` - The type of EBS volume. 55 * `kms_key_id` - The ARN for the KMS encryption key. 56 * `tags` - A mapping of tags for the resource. 57 58 [1]: http://docs.aws.amazon.com/cli/latest/reference/ec2/describe-volumes.html