Stefan Dorunga
Stefan Dorunga

Reputation: 679

How to deploy multiple applications to the same server with capistrano?

I've just finished setting up my server with phusion passenger and nginx, complete with ruby on rails that are all running swimmingly. Now I can and I have deployed an application with capistrano and I got that working right.

My issue is that I want to host several applications on different domains and deploy them with capistrano on the same server. Is this even possible or am I just hoping for too much? I couldn't seem to find anything on this so any help is appreciated.

Upvotes: 1

Views: 1336

Answers (1)

Frederick Cheung
Frederick Cheung

Reputation: 84134

If your applications are just standalone applications that don't have dependencies on each other (i.e. you deploy them individually) then just deploy them with capistrano as you normally would.

By default capistrano will deploy to a folder such as /var/www/app_name so as long as all of the apps have a different name configured in their app_name.rb they will be blissfully unaware of each other.

You may need to be a little bit more careful with some of the services you may use, e.g. you may wish to namespace your memcache keys (or run separate memcache instances) so as to avoid clashes between apps.

Upvotes: 2

Related Questions