public
Rubygem
Description: A Capistrano extension for managing and running your app on Amazon EC2.
Clone URL: git://github.com/jnewland/capsize.git
Search Repo:
put everything at the top-level
jnewland (author)
Thu Apr 10 05:04:13 -0700 2008
commit  0b97631b4da8a46442a28cd5a55834fc7c014e9e
tree    7d8e96b92606bb05fe00c722d596cc075faeba87
parent  a5815fb40023296e87c26b7d0a870753a62912f2
...
 
...
1
0
@@ -1 +1,2 @@
0
+website/*
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
0
@@ -1 +1,19 @@
0
+== 2007/06/13
0
+
0
+* Re-branded Capsize 'Capsize' with 'Capazon' no more...
0
+* Compatibility w/ Amazon EC2 (amazon-ec2) Gem v. >= 0.2.0
0
+* Lots of enhancements (See website or README.txt)
0
+
0
+== 2007/04/30
0
+
0
+* Compatibility w/ Capistrano 2.0
0
+
0
+== 2007/03/28
0
+
0
+* Fix gem dependancies
0
+
0
+== 2007/03/27
0
+
0
+* Initial Release
0
+* Provides Capistrano tasks wrapping the Amazon EC2 API
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
0
@@ -1 +1,67 @@
0
+Copyright (c) 2007 Glenn Rempe
0
+
0
+This software is distributed under the Ruby License. A copy of which is
0
+provided below.
0
+
0
+RUBY LICENSE
0
+
0
+http://www.ruby-lang.org/en/LICENSE.txt
0
+
0
+Ruby is copyrighted free software by Yukihiro Matsumoto <matz@netlab.co.jp>.
0
+You can redistribute it and/or modify it under either the terms of the GPL
0
+(see COPYING.txt file), or the conditions below:
0
+
0
+ 1. You may make and give away verbatim copies of the source form of the
0
+ software without restriction, provided that you duplicate all of the
0
+ original copyright notices and associated disclaimers.
0
+
0
+ 2. You may modify your copy of the software in any way, provided that
0
+ you do at least ONE of the following:
0
+
0
+ a) place your modifications in the Public Domain or otherwise
0
+ make them Freely Available, such as by posting said
0
+ modifications to Usenet or an equivalent medium, or by allowing
0
+ the author to include your modifications in the software.
0
+
0
+ b) use the modified software only within your corporation or
0
+ organization.
0
+
0
+ c) rename any non-standard executables so the names do not conflict
0
+ with standard executables, which must also be provided.
0
+
0
+ d) make other distribution arrangements with the author.
0
+
0
+ 3. You may distribute the software in object code or executable
0
+ form, provided that you do at least ONE of the following:
0
+
0
+ a) distribute the executables and library files of the software,
0
+ together with instructions (in the manual page or equivalent)
0
+ on where to get the original distribution.
0
+
0
+ b) accompany the distribution with the machine-readable source of
0
+ the software.
0
+
0
+ c) give non-standard executables non-standard names, with
0
+ instructions on where to get the original software distribution.
0
+
0
+ d) make other distribution arrangements with the author.
0
+
0
+ 4. You may modify and include the part of the software into any other
0
+ software (possibly commercial). But some files in the distribution
0
+ are not written by the author, so that they are not under this terms.
0
+
0
+ They are gc.c(partly), utils.c(partly), regex.[ch], st.[ch] and some
0
+ files under the ./missing directory. See each file for the copying
0
+ condition.
0
+
0
+ 5. The scripts and library files supplied as input to or produced as
0
+ output from the software do not automatically fall under the
0
+ copyright of the software, but belong to whomever generated them,
0
+ and may be sold commercially, and may be aggregated with this
0
+ software.
0
+
0
+ 6. THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
0
+ IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
0
+ WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
0
+ PURPOSE.
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
0
@@ -1 +1,33 @@
0
+History.txt
0
+License.txt
0
+Manifest.txt
0
+README.txt
0
+Rakefile
0
+config/hoe.rb
0
+config/requirements.rb
0
+examples/capsize.yml.template
0
+examples/deploy.rb
0
+examples/secure.yml.template
0
+lib/capsize.rb
0
+lib/capsize/capsize.rb
0
+lib/capsize/configuration.rb
0
+lib/capsize/ec2.rb
0
+lib/capsize/ec2_plugin.rb
0
+lib/capsize/meta_tasks.rb
0
+lib/capsize/sqs.rb
0
+lib/capsize/sqs_plugin.rb
0
+lib/capsize/version.rb
0
+script/destroy
0
+script/generate
0
+script/txt2html
0
+setup.rb
0
+tasks/deployment.rake
0
+tasks/environment.rake
0
+tasks/website.rake
0
+test/test_capsize.rb
0
+test/test_helper.rb
0
+website/index.txt
0
+website/javascripts/rounded_corners_lite.inc.js
0
+website/stylesheets/screen.css
0
+website/template.rhtml
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
0
@@ -1 +1,62 @@
0
+= Capsize
0
+
0
+Capsize provides Capistrano tasks to manage Amazon EC2. Capsize depends on the following gems being installed:
0
+
0
+ Capistrano 2.0 [ http://www.capify.org ] >= 1.99.0
0
+ Amazon EC2 [ http://amazon-ec2.rubyforge.org/ ] >= 0.2.0
0
+
0
+This project is in no way endorsed, sponsored by, or associated with Amazon, Amazon.com, or Amazon Web Services.
0
+
0
+== Installation
0
+
0
+* <tt>gem install capsize</tt>
0
+* Edit your your <tt>config/deploy.rb</tt>:
0
+
0
+<tt>
0
+# #################################################################
0
+# CAPSIZE EC2 GEM
0
+# #################################################################
0
+
0
+# Include the Capsize EC2 'cap' tasks
0
+# WARNING : This must be placed in your deploy.rb file anywhere
0
+# AFTER the line where you set your application name! Looks like:
0
+# set :application, "foobar".
0
+# The application name is used by Capsize and the order matters.
0
+require 'capsize'
0
+
0
+# Use this to overwrite the standard capsize config dir locations
0
+#set :capsize_config_dir, 'config/capsize'
0
+#set :capsize_secure_config_dir, 'config/capsize'
0
+
0
+# Use these to overwrite the actual config file names stored in the config dirs.
0
+#set :capsize_config_file_name, 'capsize.yml'
0
+#set :capsize_secure_config_file_name, 'secure.yml'
0
+</tt>
0
+
0
+* Run <tt>cap deploy:setup</tt>
0
+* Paste the generated config into config/deploy.rb
0
+
0
+== Tasks
0
+
0
+===== Notes:
0
+
0
+* <em>All tasks <b>require</b> aws_access_key_id and aws_secret_access_key.</em>
0
+* <em>All tasks optionally take environment variables in lieu of capistrano configuration variables.</em>
0
+
0
+[ec2:create_keypair] Create a keypair aws_keypair_name and write out the generate private key to aws_private_key_path.
0
+[ec2:delete_keypair] Deletes keypair aws_keypair_name.
0
+[ec2:describe_keypairs] Describes keypairs.
0
+[ec2:describe_images] Describes AMIs you have privilege to execute.
0
+[ec2:run_instance] Runs an instance of aws_ami_id with access available via aws_keypair_name.
0
+[ec2:terminate_instance] Terminates aws_instance_id.
0
+[ec2:describe_instances] Describes running AMIs.
0
+[ec2:authorize_web_and_ssh_access] Opens tcp access on port 80 and 22 to the aws_security_group.
0
+
0
+== Meta
0
+
0
+Rubyforge Project Page:: http://rubyforge.org/projects/capsize
0
+Author:: Glenn Rempe (grempe@rubyforge.org[mailto:grempe@rubyforge.org])
0
+Author:: Jesse Newland (http://soylentfoo.jnewland.com) (jnewland@gmail.com[mailto:jnewland@gmail.com])
0
+Copyright:: Copyright (c) 2007 Glenn Rempe, Jesse Newland
0
+License:: Distributes under the same terms as Ruby
...
 
 
 
 
...
1
2
3
4
0
@@ -1 +1,5 @@
0
+require 'config/requirements'
0
+require 'config/hoe' # setup Hoe + all gem configuration
0
+
0
+Dir['tasks/**/*.rake'].each { |rake| load rake }
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,19 +1 @@
0
-== 2007/06/13
0
-
0
-* Re-branded Capsize 'Capsize' with 'Capazon' no more...
0
-* Compatibility w/ Amazon EC2 (amazon-ec2) Gem v. >= 0.2.0
0
-* Lots of enhancements (See website or README.txt)
0
-
0
-== 2007/04/30
0
-
0
-* Compatibility w/ Capistrano 2.0
0
-
0
-== 2007/03/28
0
-
0
-* Fix gem dependancies
0
-
0
-== 2007/03/27
0
-
0
-* Initial Release
0
-* Provides Capistrano tasks wrapping the Amazon EC2 API
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,67 +1 @@
0
-Copyright (c) 2007 Glenn Rempe
0
-
0
-This software is distributed under the Ruby License. A copy of which is
0
-provided below.
0
-
0
-RUBY LICENSE
0
-
0
-http://www.ruby-lang.org/en/LICENSE.txt
0
-
0
-Ruby is copyrighted free software by Yukihiro Matsumoto <matz@netlab.co.jp>.
0
-You can redistribute it and/or modify it under either the terms of the GPL
0
-(see COPYING.txt file), or the conditions below:
0
-
0
- 1. You may make and give away verbatim copies of the source form of the
0
- software without restriction, provided that you duplicate all of the
0
- original copyright notices and associated disclaimers.
0
-
0
- 2. You may modify your copy of the software in any way, provided that
0
- you do at least ONE of the following:
0
-
0
- a) place your modifications in the Public Domain or otherwise
0
- make them Freely Available, such as by posting said
0
- modifications to Usenet or an equivalent medium, or by allowing
0
- the author to include your modifications in the software.
0
-
0
- b) use the modified software only within your corporation or
0
- organization.
0
-
0
- c) rename any non-standard executables so the names do not conflict
0
- with standard executables, which must also be provided.
0
-
0
- d) make other distribution arrangements with the author.
0
-
0
- 3. You may distribute the software in object code or executable
0
- form, provided that you do at least ONE of the following:
0
-
0
- a) distribute the executables and library files of the software,
0
- together with instructions (in the manual page or equivalent)
0
- on where to get the original distribution.
0
-
0
- b) accompany the distribution with the machine-readable source of
0
- the software.
0
-
0
- c) give non-standard executables non-standard names, with
0
- instructions on where to get the original software distribution.
0
-
0
- d) make other distribution arrangements with the author.
0
-
0
- 4. You may modify and include the part of the software into any other
0
- software (possibly commercial). But some files in the distribution
0
- are not written by the author, so that they are not under this terms.
0
-
0
- They are gc.c(partly), utils.c(partly), regex.[ch], st.[ch] and some
0
- files under the ./missing directory. See each file for the copying
0
- condition.
0
-
0
- 5. The scripts and library files supplied as input to or produced as
0
- output from the software do not automatically fall under the
0
- copyright of the software, but belong to whomever generated them,
0
- and may be sold commercially, and may be aggregated with this
0
- software.
0
-
0
- 6. THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
0
- IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
0
- WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
0
- PURPOSE.
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,33 +1 @@
0
-History.txt
0
-License.txt
0
-Manifest.txt
0
-README.txt
0
-Rakefile
0
-config/hoe.rb
0
-config/requirements.rb
0
-examples/capsize.yml.template
0
-examples/deploy.rb
0
-examples/secure.yml.template
0
-lib/capsize.rb
0
-lib/capsize/capsize.rb
0
-lib/capsize/configuration.rb
0
-lib/capsize/ec2.rb
0
-lib/capsize/ec2_plugin.rb
0
-lib/capsize/meta_tasks.rb
0
-lib/capsize/sqs.rb
0
-lib/capsize/sqs_plugin.rb
0
-lib/capsize/version.rb
0
-script/destroy
0
-script/generate
0
-script/txt2html
0
-setup.rb
0
-tasks/deployment.rake
0
-tasks/environment.rake
0
-tasks/website.rake
0
-test/test_capsize.rb
0
-test/test_helper.rb
0
-website/index.txt
0
-website/javascripts/rounded_corners_lite.inc.js
0
-website/stylesheets/screen.css
0
-website/template.rhtml
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,62 +1 @@
0
-= Capsize
0
-
0
-Capsize provides Capistrano tasks to manage Amazon EC2. Capsize depends on the following gems being installed:
0
-
0
- Capistrano 2.0 [ http://www.capify.org ] >= 1.99.0
0
- Amazon EC2 [ http://amazon-ec2.rubyforge.org/ ] >= 0.2.0
0
-
0
-This project is in no way endorsed, sponsored by, or associated with Amazon, Amazon.com, or Amazon Web Services.
0
-
0
-== Installation
0
-
0
-* <tt>gem install capsize</tt>
0
-* Edit your your <tt>config/deploy.rb</tt>:
0
-
0
-<tt>
0
-# #################################################################
0
-# CAPSIZE EC2 GEM
0
-# #################################################################
0
-
0
-# Include the Capsize EC2 'cap' tasks
0
-# WARNING : This must be placed in your deploy.rb file anywhere
0
-# AFTER the line where you set your application name! Looks like:
0
-# set :application, "foobar".
0
-# The application name is used by Capsize and the order matters.
0
-require 'capsize'
0
-
0
-# Use this to overwrite the standard capsize config dir locations
0
-#set :capsize_config_dir, 'config/capsize'
0
-#set :capsize_secure_config_dir, 'config/capsize'
0
-
0
-# Use these to overwrite the actual config file names stored in the config dirs.
0
-#set :capsize_config_file_name, 'capsize.yml'
0
-#set :capsize_secure_config_file_name, 'secure.yml'
0
-</tt>
0
-
0
-* Run <tt>cap deploy:setup</tt>
0
-* Paste the generated config into config/deploy.rb
0
-
0
-== Tasks
0
-
0
-===== Notes:
0
-
0
-* <em>All tasks <b>require</b> aws_access_key_id and aws_secret_access_key.</em>
0
-* <em>All tasks optionally take environment variables in lieu of capistrano configuration variables.</em>
0
-
0
-[ec2:create_keypair] Create a keypair aws_keypair_name and write out the generate private key to aws_private_key_path.
0
-[ec2:delete_keypair] Deletes keypair aws_keypair_name.
0
-[ec2:describe_keypairs] Describes keypairs.
0
-[ec2:describe_images] Describes AMIs you have privilege to execute.
0
-[ec2:run_instance] Runs an instance of aws_ami_id with access available via aws_keypair_name.
0
-[ec2:terminate_instance] Terminates aws_instance_id.
0
-[ec2:describe_instances] Describes running AMIs.
0
-[ec2:authorize_web_and_ssh_access] Opens tcp access on port 80 and 22 to the aws_security_group.
0
-
0
-== Meta
0
-
0
-Rubyforge Project Page:: http://rubyforge.org/projects/capsize
0
-Author:: Glenn Rempe (grempe@rubyforge.org[mailto:grempe@rubyforge.org])
0
-Author:: Jesse Newland (http://soylentfoo.jnewland.com) (jnewland@gmail.com[mailto:jnewland@gmail.com])
0
-Copyright:: Copyright (c) 2007 Glenn Rempe, Jesse Newland
0
-License:: Distributes under the same terms as Ruby
...
1
2
3
4
...
 
 
 
 
0
@@ -1,5 +1 @@
0
-require 'config/requirements'
0
-require 'config/hoe' # setup Hoe + all gem configuration
0
-
0
-Dir['tasks/**/*.rake'].each { |rake| load rake }
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,77 +1 @@
0
-require 'capsize/version'
0
-
0
-AUTHOR = 'Glenn Rempe' # can also be an array of Authors
0
-EMAIL = "grempe@rubyforge.org"
0
-DESCRIPTION = "Capsize is a Capistrano plugin used to provide an easy way to manage and script interaction with the Amazon EC2 service using the amazon-ec2 Ruby gem."
0
-GEM_NAME = 'capsize' # what ppl will type to install your gem
0
-RUBYFORGE_PROJECT = 'capsize' # The unix name for your project
0
-HOMEPATH = "http://#{RUBYFORGE_PROJECT}.rubyforge.org"
0
-DOWNLOAD_PATH = "http://rubyforge.org/projects/#{RUBYFORGE_PROJECT}"
0
-
0
-@config_file = "~/.rubyforge/user-config.yml"
0
-@config = nil
0
-RUBYFORGE_USERNAME = "grempe"
0
-def rubyforge_username
0
- unless @config
0
- begin
0
- @config = YAML.load(File.read(File.expand_path(@config_file)))
0
- rescue
0
- puts <<-EOS
0
-ERROR: No rubyforge config file found: #{@config_file}
0
-Run 'rubyforge setup' to prepare your env for access to Rubyforge
0
- - See http://newgem.rubyforge.org/rubyforge.html for more details
0
- EOS
0
- exit
0
- end
0
- end
0
- RUBYFORGE_USERNAME.replace @config["username"]
0
-end
0
-
0
-
0
-REV = nil
0
-# UNCOMMENT IF REQUIRED:
0
-# REV = `svn info`.each {|line| if line =~ /^Revision:/ then k,v = line.split(': '); break v.chomp; else next; end} rescue nil
0
-VERS = Capsize::VERSION::STRING + (REV ? ".#{REV}" : "")
0
-RDOC_OPTS = ['--quiet', '--title', 'capsize documentation',
0
- "--opname", "index.html",
0
- "--line-numbers",
0
- "--main", "README.txt",
0
- "--inline-source"]
0
-
0
-class Hoe
0
- def extra_deps
0
- @extra_deps.reject! { |x| Array(x).first == 'hoe' }
0
- @extra_deps
0
- end
0
-end
0
-
0
-# Generate all the Rake tasks
0
-# Run 'rake -T' to see list of generated tasks (from gem root directory)
0
-hoe = Hoe.new(GEM_NAME, VERS) do |p|
0
- p.author = AUTHOR
0
- p.description = DESCRIPTION
0
- p.email = EMAIL
0
- p.summary = DESCRIPTION
0
- p.url = HOMEPATH
0
- p.rubyforge_name = RUBYFORGE_PROJECT if RUBYFORGE_PROJECT
0
- p.test_globs = ["test/**/test_*.rb"]
0
- p.clean_globs |= ['**/.*.sw?', '*.gem', '.config', '**/.DS_Store'] #An array of file patterns to delete on clean.
0
-
0
- # == Optional
0
- p.changes = p.paragraphs_of("History.txt", 0..1).join("\\n\\n")
0
- #p.extra_deps = [] # An array of rubygem dependencies [name, version], e.g. [ ['active_support', '>= 1.3.1'] ]
0
- p.extra_deps = [['capistrano', '>= 2.1.0'], ['amazon-ec2', '>= 0.2.6'], ['rcov', '>= 0.8.1.2.0'], ['SQS', '>= 0.1.5'], ['builder', '>= 2.1.2'], ['RedCloth', '>= 3.0.4']]
0
-
0
- #p.spec_extras = {} # A hash of extra values to set in the gemspec.
0
- p.spec_extras = {
0
- :extra_rdoc_files => ["README.txt", "History.txt"],
0
- :rdoc_options => RDOC_OPTS,
0
- :autorequire => "capsize"
0
- }
0
-
0
-end
0
-
0
-CHANGES = hoe.paragraphs_of('History.txt', 0..1).join("\\n\\n")
0
-PATH = (RUBYFORGE_PROJECT == GEM_NAME) ? RUBYFORGE_PROJECT : "#{RUBYFORGE_PROJECT}/#{GEM_NAME}"
0
-hoe.remote_rdoc_dir = File.join(PATH.gsub(/^#{RUBYFORGE_PROJECT}\/?/,''), 'rdoc')
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,19 +1 @@
0
-require 'fileutils'
0
-include FileUtils
0
-
0
-require 'rubygems'
0
- %w[rake hoe newgem rubigen].each do |req_gem|
0
-
0
- begin
0
- require req_gem
0
- rescue LoadError
0
- puts "This Rakefile requires the '#{req_gem}' RubyGem."
0
- puts "Installation: gem install #{req_gem} -y"
0
- exit
0
- end
0
-end
0
-
0
-$:.unshift(File.join(File.dirname(__FILE__), %w[.. lib]))
0
-
0
-#require 'capsize'
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,67 +1 @@
0
-# capsize.yml
0
-
0
-# Regular Config Info for the Capsize (capsize) gem
0
-
0
-# This file should be setup to be deployed by capistrano
0
-# along with the rest of your application. This file should only
0
-# contain non-security related config info and thusly can be
0
-# safely versioned in your version control system.
0
-
0
-# I should be put in the RAILS_ROOT/config/capsize/secure.yml of your Ruby on Rails app
0
-# or the location of your choice if you override :capsize_config_dir
0
-
0
-# set variables in 'common' that are the same across
0
-# ALL environments. This helps us keep this file nice and DRY.
0
-common: &common
0
-
0
- # KEYPAIR CONFIG
0
- ##########################################################
0
- #defaults to the name of the :application set in deploy.rb
0
- #key_name: 'my_cool_key_name'
0
-
0
-
0
- # CAPSIZE CONFIG
0
- ##########################################################
0
- # use an ssl connection to talk to EC2? true or false allowed (no quotes)
0
- # Defaults to true
0
- #use_ssl: true
0
-
0
-
0
- # SECURITY GROUP CONFIG
0
- ##########################################################
0
- # Set the default security group to apply firewall ingress rules to.
0
- # Defaults, appropriately, to 'default' security group.
0
- #group_name: 'default'
0
-
0
- # Set the default security group ip protocol to apply firewall ingress rules to.
0
- # Defaults, appropriately, to 'tcp'.
0
- #ip_protocol: 'tcp'
0
-
0
- # other options you can override if needed
0
- #from_port: nil
0
- #to_port: nil
0
- #cidr_ip: '0.0.0.0/0'
0
- #source_security_group_name: nil
0
- #source_security_group_owner_id: nil
0
-
0
-
0
-development:
0
- <<: *common
0
-
0
- # Uncomment and I only apply to the dev environment
0
- # or overwrite a common value
0
- #foo: 'bar'
0
-
0
-test:
0
- <<: *common
0
-
0
-staging:
0
- <<: *common
0
-
0
-production:
0
- <<: *common
0
-
0
- # Uncomment and I only apply to the production environment
0
- # or overwrite a common value
0
- #foo: 'baz'
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,29 +1 @@
0
-# CAPSIZE 'deploy.rb' SAMPLE
0
-# Use this as a starting point for what you will need to add to your
0
-# standard Capistrano deploy.rb file to make it function with Capsize.
0
-
0
-# #################################################################
0
-# CAPSIZE CONFIG SETTINGS
0
-# #################################################################
0
-
0
-# Include the Capsize EC2 'cap' tasks
0
-# WARNING : This must be placed in your deploy.rb file anywhere
0
-# AFTER the line where you set your application name! Looks like:
0
-# set :application, "foobar".
0
-# The application name is used by Capsize and the order matters!
0
-require 'capsize'
0
-
0
-# Uncomment to override the standard capsize config dir
0
-# used for standard config info.
0
-#set :capsize_config_dir, 'config/capsize'
0
-
0
-# Uncomment to override location used to store a
0
-# secure config file with your AWS credentials,
0
-# and EC2 private keypair information.
0
-#set :capsize_secure_config_dir, 'config/capsize'
0
-
0
-# Uncomment to override the actual config file names
0
-# that are stored in the config dirs noted above.
0
-#set :capsize_config_file_name, 'capsize.yml'
0
-#set :capsize_secure_config_file_name, 'secure.yml'
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
@@ -1,42 +1 @@
0
-# secure.yml
0
-
0
-# Secure Config Info for the Amazon EC2 (amazon-ec2)
0
-# and Capsize (capsize) gems
0
-
0
-# WARNING : DO NOT VERSION IN SOURCE CONTROL AS IT CONTAINS PASSWORDS AND KEYS
0
-# You wouldn't want others to be able to browse your source history
0
-# and see you secret identity would you? Tip : Commit the
0
-# template version of this file in the config dir with empty
0
-# AWS identity info. That way its easy to recreate the structure of the file if you
0
-# lose your real config file somehow.
0
-
0
-# This file should be setup to be deployed by Capistrano
0
-# along with the rest of your application.
0
-
0
-# I should be put in the RAILS_ROOT/config/capsize/secure.yml of your Ruby on Rails app
0
-# or the location of your choice if you override :capsize_secure_config_dir
0
-
0
-common: &common
0
- aws_access_key_id: '__YOUR_ACCESS_KEY_ID__'
0
- aws_secret_access_key: '__YOUR_SECRET_ACCESS_KEY__'
0
-
0
-development:
0
- <<: *common
0
-
0
- # Uncomment and I only apply to the dev environment
0
- # or overwrite a common value
0
- #foo: 'bar'
0
-
0
-test:
0
- <<: *common
0
-
0
-staging:
0
- <<: *common
0
-
0
-production:
0
- <<: *common
0
-
0
- # Uncomment and I only apply to the production environment
0
- # or overwrite a common value
0
- #foo: 'baz'