The rubber plugin enables relatively complex multi-instance deployments of
RubyOnRails applications to Amazon's Elastic Compute Cloud (EC2).
See the documentation in the github wiki for more details:
http://github.com/wr0ngway/rubber/wikis
== Koonen Extensions
* Github added as a source for Ruby gems
* ImageMagic and RMagick are installed on bootstraping
* Solr management commads -- cap rubber:solr:start/stop/restart
They expect to find scripts like solr.start/solr.stop at RAILS_ROOT/mySolr dir.
* Database incrementatal backups to S3 every 5 mins
* Full database backup once a day at 3 AM
* Full Solr index backup onece a day at 4 AM
* Cap tasks to backup/restore: cap rubber:backup, :backup_db, :backup_solr, :restore, :restore_db, :restore_solr
* Samples of config files for m1.small & m1.large instance types are added to rubber/samples dir.
Basically variable parameters are: the number of mongrel, number of nginx workers, database & memcache memory settings.
* Cap task koonen:deploy:cold works like original deploy:cold,
but loads database dump from db/dump/project.sql instead of running migrations.
=== Configuration
* Solr index dir in rubber-solr.yml/solr_index_dir (default is "solr")
* EC2 backup bucket in rubber.yml/ec2_backup_bucket (default id app-backups)
NOTE: bucket must already exist.
=== Thin support
* After thin configs are generated all standard tasks (deploy:start/stop/restart) will just work with thin.
There are no need to call low-level rubber:thin:start/stop/restart directly.
* To add thin support for a new app:
script/generate vulcanize thin
or to generate a full rails stack with thin instead of mongrel:
script/generate vulcanize complete_mysql_thin
* To add thin support to the existing mongrel app:
- stop all services:
cap deploy:stop
- remove mongrel configs:
script/destroy vulcanize mongrel
- add thin configs:
script/generate vulcanize thin
- redeploy the app:
cap deploy:cold (or cap koonen:deploy:cold)
=== Solr support
* To make Solr-related tasks work, the instance should have "solr" role,
so it should be started with something like:
ALIAS=production ROLES=web,haproxy,app,mysql_master,solr