poolparty 0.0.4 → 0.2.6
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +25 -0
- data/License.txt +20 -0
- data/Manifest.txt +203 -0
- data/PostInstall.txt +18 -0
- data/README.txt +21 -82
- data/Rakefile +25 -18
- data/bin/cloud +31 -0
- data/bin/cloud-add-keypair +23 -0
- data/bin/cloud-configure +31 -0
- data/bin/cloud-contract +27 -0
- data/bin/cloud-expand +27 -0
- data/bin/cloud-list +32 -0
- data/bin/cloud-maintain +36 -0
- data/bin/cloud-osxcopy +22 -0
- data/bin/cloud-provision +31 -0
- data/bin/cloud-refresh +26 -0
- data/bin/cloud-ssh +18 -0
- data/bin/cloud-start +32 -0
- data/bin/cloud-terminate +23 -0
- data/bin/pool +25 -27
- data/bin/pool-console +12 -0
- data/bin/pool-describe +9 -0
- data/bin/pool-list +28 -0
- data/bin/pool-provision +34 -0
- data/bin/pool-spec +17 -0
- data/bin/pool-start +32 -0
- data/bin/pool-start-monitor +1 -0
- data/config/hoe.rb +115 -0
- data/config/requirements.rb +15 -0
- data/examples/basic.rb +20 -0
- data/examples/plugin_without_plugin_directory.rb +13 -0
- data/examples/poolparty.rb +12 -0
- data/examples/with_apache_plugin.rb +22 -0
- data/generators/poolspec/USAGE +5 -0
- data/generators/poolspec/poolspec_generator.rb +65 -0
- data/generators/poolspec/templates/pool_spec_template.erb +9 -0
- data/lib/erlang/eb_server.erl +27 -0
- data/lib/poolparty.rb +56 -0
- data/lib/poolparty/base_packages/haproxy.rb +42 -0
- data/lib/poolparty/base_packages/heartbeat.rb +45 -0
- data/lib/poolparty/base_packages/poolparty.rb +36 -0
- data/lib/poolparty/base_packages/ruby.rb +43 -0
- data/lib/poolparty/core/array.rb +24 -0
- data/lib/{core → poolparty/core}/exception.rb +0 -0
- data/lib/poolparty/core/float.rb +13 -0
- data/lib/poolparty/core/hash.rb +29 -0
- data/lib/poolparty/core/kernel.rb +37 -0
- data/lib/{core → poolparty/core}/module.rb +18 -0
- data/lib/poolparty/core/my_open_struct.rb +18 -0
- data/lib/poolparty/core/object.rb +54 -0
- data/lib/poolparty/core/proc.rb +7 -0
- data/lib/poolparty/core/string.rb +72 -0
- data/lib/poolparty/core/symbol.rb +8 -0
- data/lib/{core → poolparty/core}/time.rb +15 -0
- data/lib/poolparty/exceptions/RemoteException.rb +12 -0
- data/lib/poolparty/exceptions/ResourceException.rb +7 -0
- data/lib/poolparty/exceptions/RuntimeException.rb +7 -0
- data/lib/poolparty/exceptions/SpecException.rb +7 -0
- data/lib/poolparty/exceptions/TemplateNotFound.rb +7 -0
- data/lib/poolparty/helpers/binary.rb +31 -0
- data/lib/poolparty/helpers/console.rb +30 -0
- data/lib/poolparty/helpers/display.rb +34 -0
- data/lib/poolparty/helpers/optioner.rb +64 -0
- data/lib/poolparty/helpers/provisioner_base.rb +250 -0
- data/lib/poolparty/helpers/provisioners/master.rb +136 -0
- data/lib/poolparty/helpers/provisioners/slave.rb +44 -0
- data/lib/poolparty/modules/cloud_resourcer.rb +89 -0
- data/lib/poolparty/modules/configurable.rb +34 -0
- data/lib/poolparty/modules/definable_resource.rb +59 -0
- data/lib/poolparty/modules/file_writer.rb +55 -0
- data/lib/poolparty/modules/method_missing_sugar.rb +53 -0
- data/lib/poolparty/modules/output.rb +13 -0
- data/lib/poolparty/modules/pretty_printer.rb +39 -0
- data/lib/{core/string.rb → poolparty/modules/s3_string.rb} +5 -22
- data/lib/{modules → poolparty/modules}/safe_instance.rb +0 -0
- data/lib/poolparty/monitors/base_monitor.rb +16 -0
- data/lib/poolparty/net/remote.rb +35 -0
- data/lib/poolparty/net/remote_bases/ec2.rb +148 -0
- data/lib/poolparty/net/remote_instance.rb +69 -0
- data/lib/poolparty/net/remoter.rb +224 -0
- data/lib/poolparty/net/remoter_base.rb +117 -0
- data/lib/poolparty/plugins/gem_package.rb +17 -0
- data/lib/poolparty/plugins/git.rb +41 -0
- data/lib/poolparty/plugins/line.rb +76 -0
- data/lib/poolparty/plugins/svn.rb +48 -0
- data/lib/poolparty/pool/base.rb +75 -0
- data/lib/poolparty/pool/cloud.rb +164 -0
- data/lib/poolparty/pool/custom_resource.rb +61 -0
- data/lib/poolparty/pool/loggable.rb +29 -0
- data/lib/poolparty/pool/plugin.rb +41 -0
- data/lib/poolparty/pool/plugin_model.rb +48 -0
- data/lib/poolparty/pool/pool.rb +55 -0
- data/lib/poolparty/pool/resource.rb +248 -0
- data/lib/poolparty/pool/resources/class_package.rb +64 -0
- data/lib/poolparty/pool/resources/conditional.rb +41 -0
- data/lib/poolparty/pool/resources/cron.rb +14 -0
- data/lib/poolparty/pool/resources/directory.rb +23 -0
- data/lib/poolparty/pool/resources/exec.rb +26 -0
- data/lib/poolparty/pool/resources/file.rb +23 -0
- data/lib/poolparty/pool/resources/gem.rb +14 -0
- data/lib/poolparty/pool/resources/host.rb +14 -0
- data/lib/poolparty/pool/resources/package.rb +14 -0
- data/lib/poolparty/pool/resources/remote_file.rb +22 -0
- data/lib/poolparty/pool/resources/service.rb +21 -0
- data/lib/poolparty/pool/resources/sshkey.rb +19 -0
- data/lib/poolparty/pool/resources/variable.rb +27 -0
- data/lib/poolparty/pool/script.rb +44 -0
- data/lib/poolparty/templates/authkeys +2 -0
- data/{config/monit/nginx.monit.conf → lib/poolparty/templates/cib.xml} +0 -0
- data/lib/poolparty/templates/fileserver.conf +4 -0
- data/lib/poolparty/templates/gem +25 -0
- data/{config/heartbeat.conf → lib/poolparty/templates/ha.cf} +3 -2
- data/{config → lib/poolparty/templates}/haproxy.conf +13 -6
- data/lib/poolparty/templates/namespaceauth.conf +19 -0
- data/lib/poolparty/templates/puppet.conf +17 -0
- data/lib/poolparty/version.rb +9 -0
- data/lib/poolpartycl.rb +3 -0
- data/poolparty.gemspec +56 -47
- data/script/destroy +14 -0
- data/script/generate +14 -0
- data/script/txt2html +82 -0
- data/setup.rb +1585 -0
- data/spec/poolparty/base_packages/haproxy_spec.rb +13 -0
- data/spec/poolparty/base_packages/heartbeat_spec.rb +30 -0
- data/spec/poolparty/bin/console_spec.rb +80 -0
- data/spec/poolparty/core/array_spec.rb +26 -0
- data/spec/poolparty/core/float.rb +13 -0
- data/spec/poolparty/core/hash_spec.rb +63 -0
- data/spec/poolparty/core/kernel_spec.rb +24 -0
- data/spec/poolparty/core/module_spec.rb +15 -0
- data/spec/poolparty/core/object_spec.rb +40 -0
- data/spec/poolparty/core/string_spec.rb +152 -0
- data/spec/poolparty/core/time_spec.rb +52 -0
- data/spec/poolparty/helpers/binary_spec.rb +26 -0
- data/spec/poolparty/helpers/display_spec.rb +13 -0
- data/spec/poolparty/helpers/optioner_spec.rb +39 -0
- data/spec/poolparty/helpers/provisioner_base_spec.rb +121 -0
- data/spec/poolparty/helpers/provisioners/master_spec.rb +54 -0
- data/spec/poolparty/helpers/provisioners/slave_spec.rb +28 -0
- data/spec/poolparty/modules/cloud_resourcer_spec.rb +135 -0
- data/spec/poolparty/modules/configurable_spec.rb +26 -0
- data/spec/poolparty/modules/definable_resource.rb +9 -0
- data/spec/poolparty/modules/file_writer_spec.rb +49 -0
- data/spec/poolparty/modules/s3_string_spec.rb +15 -0
- data/spec/poolparty/modules/tmp/willy/nilly.rb +1 -0
- data/spec/poolparty/net/remote_bases/ec2_spec.rb +92 -0
- data/spec/poolparty/net/remote_instance_spec.rb +70 -0
- data/spec/poolparty/net/remote_spec.rb +286 -0
- data/spec/poolparty/net/remoter_base_spec.rb +80 -0
- data/spec/poolparty/net/remoter_spec.rb +191 -0
- data/spec/poolparty/plugins/git_spec.rb +33 -0
- data/spec/poolparty/plugins/line_spec.rb +16 -0
- data/spec/poolparty/plugins/svn_spec.rb +16 -0
- data/spec/poolparty/pool/base_spec.rb +108 -0
- data/spec/poolparty/pool/cloud_spec.rb +299 -0
- data/spec/poolparty/pool/configurers/files/ruby_basic.rb +17 -0
- data/spec/poolparty/pool/configurers/files/ruby_plugins.rb +16 -0
- data/spec/poolparty/pool/configurers/ruby_spec.rb +58 -0
- data/spec/poolparty/pool/custom_resource_spec.rb +115 -0
- data/spec/poolparty/pool/example_spec.rb +112 -0
- data/spec/poolparty/pool/plugin_model_spec.rb +63 -0
- data/spec/poolparty/pool/plugin_spec.rb +85 -0
- data/spec/poolparty/pool/pool_spec.rb +83 -0
- data/spec/poolparty/pool/resource_spec.rb +224 -0
- data/spec/poolparty/pool/resources/class_package_spec.rb +84 -0
- data/spec/poolparty/pool/resources/conditional_spec.rb +38 -0
- data/spec/poolparty/pool/resources/cron_spec.rb +49 -0
- data/spec/poolparty/pool/resources/directory_spec.rb +40 -0
- data/spec/poolparty/pool/resources/exec_spec.rb +37 -0
- data/spec/poolparty/pool/resources/file_spec.rb +40 -0
- data/spec/poolparty/pool/resources/gem_spec.rb +16 -0
- data/spec/poolparty/pool/resources/host_spec.rb +28 -0
- data/spec/poolparty/pool/resources/package_spec.rb +44 -0
- data/spec/poolparty/pool/resources/remote_file_spec.rb +40 -0
- data/spec/poolparty/pool/resources/service_spec.rb +45 -0
- data/spec/poolparty/pool/resources/sshkey_spec.rb +48 -0
- data/spec/poolparty/pool/resources/variable_spec.rb +20 -0
- data/spec/poolparty/pool/script_spec.rb +51 -0
- data/spec/poolparty/pool/test_plugins/sshkey_test +2 -0
- data/{test/test_pool_party.rb → spec/poolparty/pool/test_plugins/virtual_host_template.erb} +0 -0
- data/spec/poolparty/pool/test_plugins/webserver.rb +46 -0
- data/spec/poolparty/poolparty_spec.rb +33 -0
- data/spec/poolparty/spec_helper.rb +120 -0
- data/tasks/cloud.rake +57 -0
- data/tasks/deployment.rake +34 -0
- data/tasks/development.rake +78 -0
- data/tasks/ec2.rake +20 -0
- data/tasks/environment.rake +7 -0
- data/tasks/instance.rake +63 -0
- data/tasks/server.rake +42 -0
- data/tasks/spec.rake +17 -0
- data/tasks/website.rake +17 -0
- data/test/test_generator_helper.rb +29 -0
- data/test/test_helper.rb +2 -0
- data/test/test_pool_spec_generator.rb +47 -0
- data/test/test_poolparty.rb +11 -0
- data/test_manifest.pp +538 -0
- data/website/index.html +107 -0
- data/website/index.txt +95 -0
- data/website/javascripts/rounded_corners_lite.inc.js +285 -0
- data/website/stylesheets/code.css +29 -0
- data/website/stylesheets/screen.css +147 -0
- data/website/template.html.erb +49 -0
- metadata +282 -101
- data/CHANGELOG +0 -4
- data/Manifest +0 -55
- data/bin/instance +0 -54
- data/config/config.yml +0 -23
- data/config/create_proxy_ami.sh +0 -582
- data/config/heartbeat_authkeys.conf +0 -2
- data/config/monit.conf +0 -8
- data/config/monit/haproxy.monit.conf +0 -7
- data/config/nginx.conf +0 -24
- data/lib/core/array.rb +0 -10
- data/lib/core/kernel.rb +0 -9
- data/lib/core/object.rb +0 -14
- data/lib/modules/callback.rb +0 -55
- data/lib/modules/ec2_wrapper.rb +0 -74
- data/lib/pool_party.rb +0 -69
- data/lib/pool_party/application.rb +0 -133
- data/lib/pool_party/init.rb +0 -4
- data/lib/pool_party/master.rb +0 -189
- data/lib/pool_party/monitors.rb +0 -13
- data/lib/pool_party/monitors/cpu.rb +0 -18
- data/lib/pool_party/monitors/memory.rb +0 -21
- data/lib/pool_party/monitors/web.rb +0 -18
- data/lib/pool_party/optioner.rb +0 -16
- data/lib/pool_party/os.rb +0 -11
- data/lib/pool_party/os/ubuntu.rb +0 -78
- data/lib/pool_party/remote_instance.rb +0 -180
- data/lib/pool_party/remoting.rb +0 -112
- data/lib/pool_party/scheduler.rb +0 -93
- data/lib/pool_party/tasks.rb +0 -220
- data/lib/s3/s3_object_store_folders.rb +0 -44
- data/spec/application_spec.rb +0 -32
- data/spec/callback_spec.rb +0 -65
- data/spec/helpers/ec2_mock.rb +0 -56
- data/spec/helpers/remote_instance_mock.rb +0 -11
- data/spec/kernel_spec.rb +0 -11
- data/spec/master_spec.rb +0 -147
- data/spec/monitor_spec.rb +0 -16
- data/spec/optioner_spec.rb +0 -22
- data/spec/poolparty_spec.rb +0 -8
- data/spec/remote_instance_spec.rb +0 -29
- data/spec/remoting_spec.rb +0 -75
- data/spec/spec_helper.rb +0 -38
- data/spec/string_spec.rb +0 -28
data/History.txt
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
== 0.2.6 2008-10-14
|
2
|
+
* Maintaining the cloud
|
3
|
+
|
4
|
+
== 0.2 2008-09-02
|
5
|
+
* Finished new syntax rewrite
|
6
|
+
|
7
|
+
== 0.1.2 2008-08-05
|
8
|
+
* Added development tasks for easy setup
|
9
|
+
* Updated Scheduler to include ThreadPool for threaded safety
|
10
|
+
* Added poolnotify
|
11
|
+
* Updating gem on github
|
12
|
+
* Changed configuration style to rsync all files across every instance
|
13
|
+
* Moved configuration back to a configure scrip
|
14
|
+
* Added in vlad configuration
|
15
|
+
* Added plugin ability to install custom software
|
16
|
+
* Updated configuration style
|
17
|
+
* Added cloud_list to pool
|
18
|
+
* Changed listing of the clouds through pool
|
19
|
+
* Added plugin_manager
|
20
|
+
* Moved remoting to rake remote task (from vlad)
|
21
|
+
* Changed configuration from instance-based to cloud-based
|
22
|
+
* Updated source
|
23
|
+
* Plugin support
|
24
|
+
* Cleaned up base
|
25
|
+
* Extensible monitoring
|
data/License.txt
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2008 Ari Lerner
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/Manifest.txt
ADDED
@@ -0,0 +1,203 @@
|
|
1
|
+
History.txt
|
2
|
+
License.txt
|
3
|
+
Manifest.txt
|
4
|
+
PostInstall.txt
|
5
|
+
README.txt
|
6
|
+
Rakefile
|
7
|
+
bin/cloud
|
8
|
+
bin/cloud-add-keypair
|
9
|
+
bin/cloud-configure
|
10
|
+
bin/cloud-contract
|
11
|
+
bin/cloud-expand
|
12
|
+
bin/cloud-list
|
13
|
+
bin/cloud-maintain
|
14
|
+
bin/cloud-osxcopy
|
15
|
+
bin/cloud-provision
|
16
|
+
bin/cloud-refresh
|
17
|
+
bin/cloud-ssh
|
18
|
+
bin/cloud-start
|
19
|
+
bin/cloud-terminate
|
20
|
+
bin/pool
|
21
|
+
bin/pool-console
|
22
|
+
bin/pool-describe
|
23
|
+
bin/pool-list
|
24
|
+
bin/pool-provision
|
25
|
+
bin/pool-spec
|
26
|
+
bin/pool-start
|
27
|
+
bin/pool-start-monitor
|
28
|
+
config/hoe.rb
|
29
|
+
config/requirements.rb
|
30
|
+
examples/basic.rb
|
31
|
+
examples/plugin_without_plugin_directory.rb
|
32
|
+
examples/poolparty.rb
|
33
|
+
examples/with_apache_plugin.rb
|
34
|
+
generators/poolspec/USAGE
|
35
|
+
generators/poolspec/poolspec_generator.rb
|
36
|
+
generators/poolspec/templates/pool_spec_template.erb
|
37
|
+
lib/erlang/eb_server.erl
|
38
|
+
lib/poolparty.rb
|
39
|
+
lib/poolparty/base_packages/haproxy.rb
|
40
|
+
lib/poolparty/base_packages/heartbeat.rb
|
41
|
+
lib/poolparty/base_packages/poolparty.rb
|
42
|
+
lib/poolparty/base_packages/ruby.rb
|
43
|
+
lib/poolparty/core/array.rb
|
44
|
+
lib/poolparty/core/exception.rb
|
45
|
+
lib/poolparty/core/float.rb
|
46
|
+
lib/poolparty/core/hash.rb
|
47
|
+
lib/poolparty/core/kernel.rb
|
48
|
+
lib/poolparty/core/module.rb
|
49
|
+
lib/poolparty/core/my_open_struct.rb
|
50
|
+
lib/poolparty/core/object.rb
|
51
|
+
lib/poolparty/core/proc.rb
|
52
|
+
lib/poolparty/core/string.rb
|
53
|
+
lib/poolparty/core/symbol.rb
|
54
|
+
lib/poolparty/core/time.rb
|
55
|
+
lib/poolparty/exceptions/RemoteException.rb
|
56
|
+
lib/poolparty/exceptions/ResourceException.rb
|
57
|
+
lib/poolparty/exceptions/RuntimeException.rb
|
58
|
+
lib/poolparty/exceptions/SpecException.rb
|
59
|
+
lib/poolparty/exceptions/TemplateNotFound.rb
|
60
|
+
lib/poolparty/helpers/binary.rb
|
61
|
+
lib/poolparty/helpers/console.rb
|
62
|
+
lib/poolparty/helpers/display.rb
|
63
|
+
lib/poolparty/helpers/optioner.rb
|
64
|
+
lib/poolparty/helpers/provisioner_base.rb
|
65
|
+
lib/poolparty/helpers/provisioners/master.rb
|
66
|
+
lib/poolparty/helpers/provisioners/slave.rb
|
67
|
+
lib/poolparty/modules/cloud_resourcer.rb
|
68
|
+
lib/poolparty/modules/configurable.rb
|
69
|
+
lib/poolparty/modules/definable_resource.rb
|
70
|
+
lib/poolparty/modules/file_writer.rb
|
71
|
+
lib/poolparty/modules/method_missing_sugar.rb
|
72
|
+
lib/poolparty/modules/output.rb
|
73
|
+
lib/poolparty/modules/pretty_printer.rb
|
74
|
+
lib/poolparty/modules/s3_string.rb
|
75
|
+
lib/poolparty/modules/safe_instance.rb
|
76
|
+
lib/poolparty/monitors/base_monitor.rb
|
77
|
+
lib/poolparty/net/remote.rb
|
78
|
+
lib/poolparty/net/remote_bases/ec2.rb
|
79
|
+
lib/poolparty/net/remote_instance.rb
|
80
|
+
lib/poolparty/net/remoter.rb
|
81
|
+
lib/poolparty/net/remoter_base.rb
|
82
|
+
lib/poolparty/plugins/gem_package.rb
|
83
|
+
lib/poolparty/plugins/git.rb
|
84
|
+
lib/poolparty/plugins/line.rb
|
85
|
+
lib/poolparty/plugins/svn.rb
|
86
|
+
lib/poolparty/pool/base.rb
|
87
|
+
lib/poolparty/pool/cloud.rb
|
88
|
+
lib/poolparty/pool/custom_resource.rb
|
89
|
+
lib/poolparty/pool/loggable.rb
|
90
|
+
lib/poolparty/pool/plugin.rb
|
91
|
+
lib/poolparty/pool/plugin_model.rb
|
92
|
+
lib/poolparty/pool/pool.rb
|
93
|
+
lib/poolparty/pool/resource.rb
|
94
|
+
lib/poolparty/pool/resources/class_package.rb
|
95
|
+
lib/poolparty/pool/resources/conditional.rb
|
96
|
+
lib/poolparty/pool/resources/cron.rb
|
97
|
+
lib/poolparty/pool/resources/directory.rb
|
98
|
+
lib/poolparty/pool/resources/exec.rb
|
99
|
+
lib/poolparty/pool/resources/file.rb
|
100
|
+
lib/poolparty/pool/resources/gem.rb
|
101
|
+
lib/poolparty/pool/resources/host.rb
|
102
|
+
lib/poolparty/pool/resources/package.rb
|
103
|
+
lib/poolparty/pool/resources/remote_file.rb
|
104
|
+
lib/poolparty/pool/resources/service.rb
|
105
|
+
lib/poolparty/pool/resources/sshkey.rb
|
106
|
+
lib/poolparty/pool/resources/variable.rb
|
107
|
+
lib/poolparty/pool/script.rb
|
108
|
+
lib/poolparty/templates/authkeys
|
109
|
+
lib/poolparty/templates/cib.xml
|
110
|
+
lib/poolparty/templates/fileserver.conf
|
111
|
+
lib/poolparty/templates/gem
|
112
|
+
lib/poolparty/templates/ha.cf
|
113
|
+
lib/poolparty/templates/haproxy.conf
|
114
|
+
lib/poolparty/templates/namespaceauth.conf
|
115
|
+
lib/poolparty/templates/puppet.conf
|
116
|
+
lib/poolparty/version.rb
|
117
|
+
lib/poolpartycl.rb
|
118
|
+
poolparty.gemspec
|
119
|
+
script/destroy
|
120
|
+
script/generate
|
121
|
+
script/txt2html
|
122
|
+
setup.rb
|
123
|
+
spec/poolparty/base_packages/haproxy_spec.rb
|
124
|
+
spec/poolparty/base_packages/heartbeat_spec.rb
|
125
|
+
spec/poolparty/bin/console_spec.rb
|
126
|
+
spec/poolparty/core/array_spec.rb
|
127
|
+
spec/poolparty/core/float.rb
|
128
|
+
spec/poolparty/core/hash_spec.rb
|
129
|
+
spec/poolparty/core/kernel_spec.rb
|
130
|
+
spec/poolparty/core/module_spec.rb
|
131
|
+
spec/poolparty/core/object_spec.rb
|
132
|
+
spec/poolparty/core/string_spec.rb
|
133
|
+
spec/poolparty/core/time_spec.rb
|
134
|
+
spec/poolparty/helpers/binary_spec.rb
|
135
|
+
spec/poolparty/helpers/display_spec.rb
|
136
|
+
spec/poolparty/helpers/optioner_spec.rb
|
137
|
+
spec/poolparty/helpers/provisioner_base_spec.rb
|
138
|
+
spec/poolparty/helpers/provisioners/master_spec.rb
|
139
|
+
spec/poolparty/helpers/provisioners/slave_spec.rb
|
140
|
+
spec/poolparty/modules/cloud_resourcer_spec.rb
|
141
|
+
spec/poolparty/modules/configurable_spec.rb
|
142
|
+
spec/poolparty/modules/definable_resource.rb
|
143
|
+
spec/poolparty/modules/file_writer_spec.rb
|
144
|
+
spec/poolparty/modules/s3_string_spec.rb
|
145
|
+
spec/poolparty/modules/tmp/willy/nilly.rb
|
146
|
+
spec/poolparty/net/remote_bases/ec2_spec.rb
|
147
|
+
spec/poolparty/net/remote_instance_spec.rb
|
148
|
+
spec/poolparty/net/remote_spec.rb
|
149
|
+
spec/poolparty/net/remoter_base_spec.rb
|
150
|
+
spec/poolparty/net/remoter_spec.rb
|
151
|
+
spec/poolparty/plugins/git_spec.rb
|
152
|
+
spec/poolparty/plugins/line_spec.rb
|
153
|
+
spec/poolparty/plugins/svn_spec.rb
|
154
|
+
spec/poolparty/pool/base_spec.rb
|
155
|
+
spec/poolparty/pool/cloud_spec.rb
|
156
|
+
spec/poolparty/pool/configurers/files/ruby_basic.rb
|
157
|
+
spec/poolparty/pool/configurers/files/ruby_plugins.rb
|
158
|
+
spec/poolparty/pool/configurers/ruby_spec.rb
|
159
|
+
spec/poolparty/pool/custom_resource_spec.rb
|
160
|
+
spec/poolparty/pool/example_spec.rb
|
161
|
+
spec/poolparty/pool/plugin_model_spec.rb
|
162
|
+
spec/poolparty/pool/plugin_spec.rb
|
163
|
+
spec/poolparty/pool/pool_spec.rb
|
164
|
+
spec/poolparty/pool/resource_spec.rb
|
165
|
+
spec/poolparty/pool/resources/class_package_spec.rb
|
166
|
+
spec/poolparty/pool/resources/conditional_spec.rb
|
167
|
+
spec/poolparty/pool/resources/cron_spec.rb
|
168
|
+
spec/poolparty/pool/resources/directory_spec.rb
|
169
|
+
spec/poolparty/pool/resources/exec_spec.rb
|
170
|
+
spec/poolparty/pool/resources/file_spec.rb
|
171
|
+
spec/poolparty/pool/resources/gem_spec.rb
|
172
|
+
spec/poolparty/pool/resources/host_spec.rb
|
173
|
+
spec/poolparty/pool/resources/package_spec.rb
|
174
|
+
spec/poolparty/pool/resources/remote_file_spec.rb
|
175
|
+
spec/poolparty/pool/resources/service_spec.rb
|
176
|
+
spec/poolparty/pool/resources/sshkey_spec.rb
|
177
|
+
spec/poolparty/pool/resources/variable_spec.rb
|
178
|
+
spec/poolparty/pool/script_spec.rb
|
179
|
+
spec/poolparty/pool/test_plugins/sshkey_test
|
180
|
+
spec/poolparty/pool/test_plugins/virtual_host_template.erb
|
181
|
+
spec/poolparty/pool/test_plugins/webserver.rb
|
182
|
+
spec/poolparty/poolparty_spec.rb
|
183
|
+
spec/poolparty/spec_helper.rb
|
184
|
+
tasks/cloud.rake
|
185
|
+
tasks/deployment.rake
|
186
|
+
tasks/development.rake
|
187
|
+
tasks/ec2.rake
|
188
|
+
tasks/environment.rake
|
189
|
+
tasks/instance.rake
|
190
|
+
tasks/server.rake
|
191
|
+
tasks/spec.rake
|
192
|
+
tasks/website.rake
|
193
|
+
test/test_generator_helper.rb
|
194
|
+
test/test_helper.rb
|
195
|
+
test/test_pool_spec_generator.rb
|
196
|
+
test/test_poolparty.rb
|
197
|
+
test_manifest.pp
|
198
|
+
website/index.html
|
199
|
+
website/index.txt
|
200
|
+
website/javascripts/rounded_corners_lite.inc.js
|
201
|
+
website/stylesheets/code.css
|
202
|
+
website/stylesheets/screen.css
|
203
|
+
website/template.html.erb
|
data/PostInstall.txt
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
Get ready to jump in the pool, you just installed poolpartyrb!
|
2
|
+
|
3
|
+
To get started, run the generator:
|
4
|
+
|
5
|
+
pool spec <name>
|
6
|
+
|
7
|
+
Please check out the documentation for any questions or check out the google groups at
|
8
|
+
http://groups.google.com/group/poolpartyrb
|
9
|
+
|
10
|
+
|
11
|
+
Don't forget to check out the plugin tutorial @ http://poolpartyrb.com for extending PoolParty!
|
12
|
+
|
13
|
+
For more information, check http://PoolPartyrb.com
|
14
|
+
On IRC:
|
15
|
+
irc.freenode.net
|
16
|
+
#poolpartyrb
|
17
|
+
|
18
|
+
*** Ari Lerner @ <arilerner@mac.com> ***
|
data/README.txt
CHANGED
@@ -1,97 +1,36 @@
|
|
1
1
|
= PoolParty
|
2
|
-
|
3
|
-
|
4
|
-
CitrusByte
|
5
|
-
http://blog.citrusbyte.com
|
2
|
+
|
3
|
+
http://poolpartyrb.com
|
6
4
|
|
7
5
|
== DESCRIPTION:
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
==
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
ENV["CONFIG_FILE"] => Location of your config yaml file (optional)
|
23
|
-
ENV["EC2_HOME"] => EC2 home directory (defaults to ~/.ec2)
|
24
|
-
ENV["KEYPAIR_NAME"] => The keypair used to launch instances
|
25
|
-
The structure assumed for the keypair is EC2_HOME/id_rsa-<keypairname>
|
26
|
-
|
27
|
-
# IN A CONFIG FILE
|
28
|
-
PoolParty assumes your config directory is set in config/config.yml. However, you can set this in your environment variables and it will read the config file from the environment variable
|
29
|
-
|
30
|
-
# WITH A RAKE TASK
|
31
|
-
PoolParty comes with a rake task that can setup your environment for you. Set the environment variables above and run
|
32
|
-
rake dev:setup
|
33
|
-
This will write a .<KEYPAIR_NAME>_pool_keys into your home directory. Then you can just run
|
34
|
-
source ~/.<KEYPAIR_NAME>_pool_keys
|
35
|
-
and your environment will be all setup for you everytime you want to work on the cloud
|
36
|
-
|
37
|
-
= Basics
|
38
|
-
PoolParty can work in two ways to load balance it's traffic. It can either do server-side or client-side load-balancing. Since every instance load balances itself, you can either set the client to grab an instance and send it to that using client-side load balancing (with a js library). Alternatively, you can set the master in dns and reference it when referring to the application.
|
39
|
-
Since PoolParty makes no assumptions as to what you will be hosting on the application, the world is your oyster when running a cloud. You can set each instance to register with a dynDNS service so that your application has multiple points of entry and can run load-balanced on the fly.
|
40
|
-
Every instance will auto-mount the s3 bucket set in the config file (if it is set up) into the /data folder of the instance. This gives each instance access to the same data regardless of the instance. It uses s3fuse and caching through s3fuse in the /tmp directory to work as fast as possible on the local instances.
|
41
|
-
The instances all are loaded with the following software:
|
42
|
-
Haproxy - The basic load balancing software
|
43
|
-
Heartbeat - The failover software
|
44
|
-
S3Fuse - The mounting software for the s3 bucket
|
45
|
-
Monit - The maintainer of the services to maintain services
|
46
|
-
|
47
|
-
When an instance is started or brought down, the master is responsible for reloading every instance with the new data on each instance. If the master goes down, the next in succession will take over as the master (using heartbeat) and it will reconfigure the cloud, setting itself as the master and take over the maintenance of the cloud.
|
48
|
-
|
49
|
-
Each instance has a /etc/hosts file that has each node listed as the node name listed in the cloud:list (rake task).
|
50
|
-
|
51
|
-
= Cloud tools
|
52
|
-
The cloud can be maintained entirely through rake tasks, although there are a few front-ends being developed (one in cocoa).
|
53
|
-
All the cloud rake tasks are in the cloud namespace and are:
|
54
|
-
rake cloud:deploy # Deploy web application from production git repos spe...
|
55
|
-
rake cloud:list # List cloud
|
56
|
-
rake cloud:maintain # Maintain the cloud (run on the master)
|
57
|
-
rake cloud:prepare # Prepare all servers
|
58
|
-
rake cloud:reload # Reload all instances with updated data
|
59
|
-
rake cloud:shutdown # Shutdown the entire cloud
|
60
|
-
rake cloud:start # Start the cloud
|
61
|
-
|
62
|
-
The instance rake tasks are in the instance namespace
|
63
|
-
rake instance:configure # Configure the stack on this node
|
64
|
-
rake instance:exec # Execute cmd on a remote instance
|
65
|
-
rake instance:install # Install stack on this node
|
66
|
-
rake instance:load # Start all services
|
67
|
-
rake instance:reload # Restart all the services
|
68
|
-
rake instance:scp # Send a file to the remote instance
|
69
|
-
rake instance:shutdown # Teardown instance
|
70
|
-
rake instance:ssh # Remotely login to the remote instance
|
71
|
-
rake instance:stop # Stop all services
|
72
|
-
|
73
|
-
For more help, check http://poolpartyrb.com
|
6
|
+
|
7
|
+
COMING SOON
|
8
|
+
|
9
|
+
== FEATURES/PROBLEMS:
|
10
|
+
|
11
|
+
COMING SOON
|
12
|
+
|
13
|
+
== SYNOPSIS:
|
14
|
+
|
15
|
+
poolparty is written with the intention of being as application-agnostic as possible. It installs only the basic
|
16
|
+
required software to glue the cloud together on the instances as listed below.
|
17
|
+
|
18
|
+
poolparty is easily configuration. In fact, it makes little assumptions about your development environment and allows
|
19
|
+
several options on how to begin configuring the cloud.
|
74
20
|
|
75
21
|
== REQUIREMENTS:
|
76
|
-
* yaml
|
77
|
-
* aws/s3
|
78
|
-
* aska
|
79
|
-
* EC2
|
80
|
-
* fastthread
|
81
22
|
|
82
|
-
|
23
|
+
COMING SOON
|
83
24
|
|
84
|
-
|
25
|
+
== INSTALL:
|
85
26
|
|
86
|
-
|
87
|
-
* v0.1.0 - Add SQS task support
|
88
|
-
* v0.2.0 - Callback support
|
27
|
+
sudo gem install auser-poolparty
|
89
28
|
|
90
29
|
== LICENSE:
|
91
30
|
|
92
31
|
(The MIT License)
|
93
32
|
|
94
|
-
Copyright (c) 2008 Ari Lerner
|
33
|
+
Copyright (c) 2008 Ari Lerner
|
95
34
|
|
96
35
|
Permission is hereby granted, free of charge, to any person obtaining
|
97
36
|
a copy of this software and associated documentation files (the
|
@@ -110,4 +49,4 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
|
110
49
|
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
111
50
|
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
112
51
|
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
113
|
-
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
52
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/Rakefile
CHANGED
@@ -1,18 +1,25 @@
|
|
1
|
-
require '
|
2
|
-
require '
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
end
|
17
|
-
|
18
|
-
|
1
|
+
require 'config/requirements'
|
2
|
+
require 'config/hoe' # setup Hoe + all gem configuration
|
3
|
+
|
4
|
+
Dir['tasks/**/*.rake'].each { |rake| load rake }
|
5
|
+
|
6
|
+
desc "Clean tmp directory"
|
7
|
+
task :clean_tmp do |t|
|
8
|
+
%w(logs tmp ~).each do |dir|
|
9
|
+
FileUtils.rm_rf("#{File.dirname(__FILE__)}/#{dir}") if ::File.exists?("#{File.dirname(__FILE__)}/#{dir}")
|
10
|
+
end
|
11
|
+
end
|
12
|
+
desc "Remove the pkg directory"
|
13
|
+
task :clean_pkg do |t|
|
14
|
+
%w(pkg).each do |dir|
|
15
|
+
FileUtils.rm_rf("#{File.dirname(__FILE__)}/#{dir}") if ::File.exists?("#{File.dirname(__FILE__)}/#{dir}")
|
16
|
+
end
|
17
|
+
end
|
18
|
+
desc "Generate gemspec"
|
19
|
+
task :gemspec => [:spec, :clean_tmp, :"manifest:refresh", :local_deploy, :clean_pkg] do |t|
|
20
|
+
res = %x[rake debug_gem]
|
21
|
+
res = res.split("\n")[1..-1].join("\n")
|
22
|
+
::File.open("#{GEM_NAME.downcase}.gemspec", "w+") do |f|
|
23
|
+
f << res
|
24
|
+
end
|
25
|
+
end
|
data/bin/cloud
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
#!/usr/bin/ruby
|
2
|
+
$:.unshift(File.join(File.dirname(__FILE__), "..", "lib"))
|
3
|
+
require "poolparty"
|
4
|
+
require "poolpartycl"
|
5
|
+
|
6
|
+
# Get the git-style program action
|
7
|
+
# o = PoolParty::Optioner.new(ARGV) do |opts, optioner|
|
8
|
+
# opts.on('-n [name]','--name [name]', 'Binary to run') { |o| optioner.name o }
|
9
|
+
# end
|
10
|
+
|
11
|
+
name = ARGV.shift
|
12
|
+
|
13
|
+
# If there was no program action given
|
14
|
+
if !name || name == "-h" || name == "--help"
|
15
|
+
puts "Usage: cloud <specfile> <action> <options>"
|
16
|
+
puts "Cloud actions:"
|
17
|
+
puts Binary.list_binaries_for("cloud")
|
18
|
+
exit
|
19
|
+
end
|
20
|
+
|
21
|
+
program_name = "#{File.basename($0)}-#{name}"
|
22
|
+
program_location = File.join(Binary.binary_directory, program_name)
|
23
|
+
|
24
|
+
command_line = "#{program_location} #{ARGV.join(" ")}"
|
25
|
+
|
26
|
+
# Run it from the command-line first
|
27
|
+
if Binary.available_binaries_for("cloud").include?(name)
|
28
|
+
exec "#{command_line}"
|
29
|
+
else
|
30
|
+
puts "Unknown poolparty binary: #{program_name}"
|
31
|
+
end
|