cloudstack-cli 0.3.8 → 0.3.9
Sign up to get free protection for your applications and to get access to all the features.
@@ -3,14 +3,17 @@ class Volume < CloudstackCli::Base
|
|
3
3
|
desc "list", "list networks"
|
4
4
|
option :project
|
5
5
|
def list
|
6
|
-
|
7
|
-
|
8
|
-
if
|
9
|
-
puts "No
|
6
|
+
projectid = find_project['id'] if options[:project]
|
7
|
+
volumes = client.list_volumes(projectid)
|
8
|
+
if volumes.size < 1
|
9
|
+
puts "No volumes found."
|
10
10
|
else
|
11
|
-
table = [["Name", "
|
12
|
-
|
13
|
-
table << [
|
11
|
+
table = [["Name", "Type", "Size", "VM", "Storage", "Offeringname"]]
|
12
|
+
volumes.each do |volume|
|
13
|
+
table << [volume['name'], volume['type'],
|
14
|
+
(volume['size'] / 1024**3).to_s + 'GB',
|
15
|
+
volume['vmname'],
|
16
|
+
volume['storage'], volume['diskofferingname']]
|
14
17
|
end
|
15
18
|
print_table(table)
|
16
19
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cloudstack-cli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.9
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-10-
|
12
|
+
date: 2013-10-24 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rdoc
|