sumo 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/README.rdoc +23 -1
  2. data/VERSION +1 -1
  3. data/lib/sumo.rb +4 -4
  4. metadata +2 -2
@@ -17,7 +17,26 @@ Later...
17
17
  $ sumo terminate
18
18
  ec2-67-202-17-178.compute-1.amazonaws.com scheduled for termination
19
19
 
20
- You can also manage multiple instances via "sumo list" and specifying hostname or instance id as arguments to the launch, ssh, and terminate commands.
20
+ You can manage multiple instances via "sumo list" and specifying hostname or instance id as arguments to the ssh or terminate commands.
21
+
22
+ == Service installation with Chef
23
+
24
+ The launch command takes an argument, which is a server role (from roles/#{role}.json inside your cookbooks repo):
25
+
26
+ $ sumo launch redis
27
+ ---> Launch instance... i-b96c73d0 (1.3s)
28
+ ---> Acquire hostname... ec2-75-101-191-220.compute-1.amazonaws.com (36.1s)
29
+ ---> Wait for ssh... done (9.0s)
30
+ ---> Bootstrap chef... done (61.3s)
31
+ ---> Setup redis... done (11.9s)
32
+ ---> Opening firewall... ports 6379 (5.2s)
33
+
34
+ Your instance is exporting the following resources:
35
+ Redis: redis://:8452cdd98f428c972f08@ec2-75-101-191-220.compute-1.amazonaws.com:6379/0
36
+
37
+ The instance can assume multiple roles if you like:
38
+
39
+ $ sumo launch redis,solr,couchdb
21
40
 
22
41
  == Setup
23
42
 
@@ -31,6 +50,7 @@ Then create ~/.sumo/config.yml containing:
31
50
  access_id: <your amazon access key id>
32
51
  access_secret: <your amazon secret access key>
33
52
  ami: ami-ed46a784
53
+ cookbooks_url: git://github.com/adamwiggins/chef-cookbooks.git
34
54
 
35
55
  If you run any production machines from your EC2 account, I recommend setting up a separate account for use with Sumo. It does not prompt for confirmation when terminating an instance or differentiate between instances started by it vs. instances started by other tools.
36
56
 
@@ -40,6 +60,8 @@ Launch, ssh to, and terminate instances.
40
60
 
41
61
  Sumo creates its own keypair named sumo, which is stored in ~/.ssh/keypair.pem. Amazon doesn't let you upload your own ssh public key, which is lame, so this is the best option for making the launch-and-connect process a single step.
42
62
 
63
+ It will also create an Amazon security group called sumo, so that it can lower the firewall for services you configure via cookbook roles.
64
+
43
65
  == Anti-features
44
66
 
45
67
  Sumo is not a cloud management tool, a monitor tool, or anything more than a way to get an instance up right quick. If you're looking for a way to manage a cluster of production instances, try one of these fine tools.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.0
1
+ 0.1.1
@@ -1,4 +1,4 @@
1
- require 'ec2'
1
+ require 'AWS'
2
2
  require 'yaml'
3
3
  require 'socket'
4
4
 
@@ -172,7 +172,7 @@ class Sumo
172
172
 
173
173
  def create_security_group
174
174
  ec2.create_security_group(:group_name => 'sumo', :group_description => 'Sumo')
175
- rescue EC2::InvalidGroupDuplicate
175
+ rescue AWS::EC2::InvalidGroupDuplicate
176
176
  end
177
177
 
178
178
  def open_firewall(port)
@@ -183,10 +183,10 @@ class Sumo
183
183
  :to_port => port,
184
184
  :cidr_ip => '0.0.0.0/0'
185
185
  )
186
- rescue EC2::InvalidPermissionDuplicate
186
+ rescue AWS::EC2::InvalidPermissionDuplicate
187
187
  end
188
188
 
189
189
  def ec2
190
- @ec2 ||= EC2::Base.new(:access_key_id => config['access_id'], :secret_access_key => config['access_secret'])
190
+ @ec2 ||= AWS::EC2::Base.new(:access_key_id => config['access_id'], :secret_access_key => config['access_secret'])
191
191
  end
192
192
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sumo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.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-08-19 00:00:00 -07:00
12
+ date: 2009-08-31 00:00:00 -07:00
13
13
  default_executable: sumo
14
14
  dependencies: []
15
15