Published on November 18, 2008
Ruby Deployment Ezra Zygmuntowicz http://engineyard.com
Apache + FastCGI
Lighttpd + FastCGI
Lighttpd + SCGI
Apache + FCGID
Mongrel + Apache
Mongrel + Lighttpd
Mongrel + Nginx WIN!
Thin or Ebb + Nginx WIN!(sometimes)
State of the art now: Passenger for shared hosting/small VPS Nginx + Mongrel or Thin for high volume production deployments
Woah! That is 10 different options!
Woah! That is 10 different options! And I rewrote my deployment book almost that many times :(
And it was already out of date when it shipped ;)
Rack: the great equalizer
Now with that out of the way...
Nanite: A world of services
Nanite is a new way of building scalable backends for web apps
Built around RabbitMQ • Written in erlang, clusterable, highly scalable, fast as hell. • AMQP protocol provides many nice features • Transient, Persistent and Transactional semantics
Nanite agents consist of multiple Actors
Nanite agents advertise their services and status Feeds#crawl advertises: /feeds/crawl Load average is advertised as default status
Nanite Mappers Track nanites and their advertised services and status Can do dispatch based on a number of factors Run inside your Merb or Rails app State of all nanites is replicated across all mappers
Multiple Dispatch Styles
Least loaded dispatch and the ﬁtness function
Agents ping the mapper exchange every @ping_time seconds. Mappers track the state of all nanites and remove them from mapping if they haven’t reported in within a timeout
Nanite gives us: • Presence, we know when nanites are ready for requests or not. • Self assembly, nanites can come and go and can run anywhere with zero conﬁguration in the mappers. • Dispatch based on load or any ﬁtness function that suits your app • Easily take advantage of cloud
Rack over Nanite
Nanite makes it easy to scale web app backends Git it on GitHub: http://github.com/ezmobius/nanite
EYAAS Engine Yard As A Service Engine Yard abstracted from Engine Yard
EYAAS Engine Yard As A Service Clouds are too low level for average humans
EYAAS Engine Yard As A Service First Target: AWS
EYAAS Engine Yard As A Service Next Target: Your own Servers in your own DC, any new cloud computing platforms that pop up.
A Different Way of Thinking
It’s all about the Automation
1. State Based Conﬁguration Management Repeatable Idempotent
1. State Based Conﬁguration Management Treat an instance like a referentially transparent function f(conﬁg) -> Fully Conﬁgured Instance Calling f(conﬁg) will *always* create the same instance whenever conﬁg == conﬁg
1. State Based Conﬁguration Management Treat instances as throw away Prefer rebuilding from scratch Only persist what truly needs to be persistent
EYAAS Custom Gentoo or Ubuntu Linux State based conﬁg management Ad hoc Change Extensive Monitoring 24/7 support High Level Cloud
EYAAS Bridge multiple providers Highly tuned databases on EY Elastic app servers on ec2 Will support any compelling new cloud platforms
JSON “DNA” describes your deployments. Servers can be built from bare metal to spec in a few minutes.
Capistrano extends the Rake DSL with methods specific to running commands on() servers. For Any Language. Capistrano is written in Ruby, but it can easily ...
Rails Deployment Tutorial. This tutorial shows how to deploy Ruby on Rails applications on Ubuntu Linux 16.04 LTS. Deploying a new version will be fully ...
The Ruby Toolbox is a comprehensive catalog of Ruby and Rails plug-ins, gems, tools and resources for Ruby developers with popularity ratings based on ...
Ruby on Rails: Deployment mit Capistrano Rangierbahnhof Ralf Wirdemann, Thomas Baustert. Größere Webprojekte will niemand Datei für Datei auf den oder ...
Sinatra is the natural choice for building fast and efficient Ruby applications without the weight of Rails.
JRuby on Rails Blog - Informationen rund um JRuby, Rails und Ruby - Agilität von Ruby mit der ausgereiften Infrastruktur und Bibliotheken der Java-Welt.
From WPKG | Open Source Software Deployment and Distribution. Jump to: ... To uninstall old versions of ruby, the following script can be used:
Azure-Beispiel: An example illustrating how to use Ruby to deploy an Azure Resource Manager Template
Deploy an SSH Enabled VM with a Template in Ruby. by David Justice. Last updated: ... azure-ruby-deployment-sample and public key located at: ...
Ruby on Rails is open source software, so not only is it free to use, you can also help make it better. More than 4,200 people already have contributed ...