adamwiggins-sumo 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.rdoc +1 -1
- data/VERSION +1 -1
- data/bin/sumo +2 -2
- data/lib/sumo.rb +4 -4
- metadata +2 -2
data/README.rdoc
CHANGED
@@ -114,7 +114,7 @@ Sumo is not a cloud management tool, a monitor tool, or anything more than a way
|
|
114
114
|
|
115
115
|
Created by Adam Wiggins
|
116
116
|
|
117
|
-
Patches contributed by Orion Henry, Blake Mizerany, and
|
117
|
+
Patches contributed by Orion Henry, Blake Mizerany, Jesse Newland, and Gert Goet
|
118
118
|
|
119
119
|
Released under the MIT License: http://www.opensource.org/licenses/mit-license.php
|
120
120
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.1
|
data/bin/sumo
CHANGED
@@ -100,13 +100,13 @@ class CLI < Thor
|
|
100
100
|
desc "volumes", "list all volumes"
|
101
101
|
def volumes
|
102
102
|
sumo.volumes.each do |v|
|
103
|
-
printf "%-10s %
|
103
|
+
printf "%-10s %4sGB %10s %15s %15s\n", v[:volume_id], v[:size], v[:status], v[:instance], v[:device]
|
104
104
|
end
|
105
105
|
end
|
106
106
|
|
107
107
|
desc "create_volume [<megabytes>]", "create a volume"
|
108
108
|
def create_volume(size=5)
|
109
|
-
task("Create #{size}
|
109
|
+
task("Create #{size}GB volume") { sumo.create_volume(size) }
|
110
110
|
end
|
111
111
|
|
112
112
|
desc "destroy_volume [<volume_id>]", "destroy a volume"
|
data/lib/sumo.rb
CHANGED
@@ -17,7 +17,7 @@ class Sumo
|
|
17
17
|
:instance_type => config['instance_size'] || 'm1.small',
|
18
18
|
:key_name => 'sumo',
|
19
19
|
:group_id => [ 'sumo' ],
|
20
|
-
:availability_zone => config['availability_zone']
|
20
|
+
:availability_zone => config['availability_zone']
|
21
21
|
)
|
22
22
|
result.instancesSet.item[0].instanceId
|
23
23
|
end
|
@@ -111,8 +111,8 @@ class Sumo
|
|
111
111
|
return unless volume_id
|
112
112
|
volume_id = volume_id.strip.downcase
|
113
113
|
volumes.detect do |volume|
|
114
|
-
|
115
|
-
|
114
|
+
volume[:volume_id] == volume_id or
|
115
|
+
volume[:volume_id].gsub(/^vol-/, '') == volume_id
|
116
116
|
end
|
117
117
|
end
|
118
118
|
|
@@ -222,7 +222,7 @@ class Sumo
|
|
222
222
|
{
|
223
223
|
'user' => 'root',
|
224
224
|
'ami' => 'ami-ed46a784',
|
225
|
-
'availability_zone' => 'us-east-1b'
|
225
|
+
'availability_zone' => 'us-east-1b'
|
226
226
|
}
|
227
227
|
end
|
228
228
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: adamwiggins-sumo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Wiggins
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-09-
|
12
|
+
date: 2009-09-10 00:00:00 -07:00
|
13
13
|
default_executable: sumo
|
14
14
|
dependencies: []
|
15
15
|
|