Method: Fog::Compute::AWS::Real#describe_volumes
- Defined in:
- lib/fog/aws/requests/compute/describe_volumes.rb
permalink #describe_volumes(filters = {}) ⇒ Object
Describe all or specified volumes.
Parameters
-
filters<~Hash> - List of filters to limit results with
Returns
-
response<~Excon::Response>:
-
body<~Hash>:
-
‘volumeSet’<~Array>:
-
‘availabilityZone’<~String> - Availability zone for volume
-
‘createTime’<~Time> - Timestamp for creation
-
‘iops’<~Integer> - Number of IOPS volume supports
-
‘size’<~Integer> - Size in GiBs for volume
-
‘snapshotId’<~String> - Snapshot volume was created from, if any
-
‘status’<~String> - State of volume
-
‘volumeId’<~String> - Reference to volume
-
‘volumeType’<~String> - Type of volume
-
‘attachmentSet’<~Array>:
-
‘attachmentTime’<~Time> - Timestamp for attachment
-
‘deleteOnTermination’<~Boolean> - Whether or not to delete volume on instance termination
-
‘device’<~String> - How value is exposed to instance
-
‘instanceId’<~String> - Reference to attached instance
-
‘status’<~String> - Attachment state
-
‘volumeId’<~String> - Reference to volume
-
-
-
-
34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/fog/aws/requests/compute/describe_volumes.rb', line 34 def describe_volumes(filters = {}) unless filters.is_a?(Hash) Fog::Logger.deprecation("describe_volumes with #{filters.class} param is deprecated, use describe_volumes('volume-id' => []) instead [light_black](#{caller.first})[/]") filters = {'volume-id' => [*filters]} end params = Fog::AWS.indexed_filters(filters) request({ 'Action' => 'DescribeVolumes', :idempotent => true, :parser => Fog::Parsers::Compute::AWS::DescribeVolumes.new }.merge!(params)) end |