# Deploying Rails app in subdomains of Rails app

**URL:** <https://www.ruby-forum.com/t/deploying-rails-app-in-subdomains-of-rails-app/91120>\
**Category:** Deployment\
**Created:** [April 4, 2007, 9:38pm UTC](https://www.ruby-forum.com/t/deploying-rails-app-in-subdomains-of-rails-app/91120 "2007-04-04T21:38:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![wpwood](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/d6d6ee/32.png) [@wpwood](https://www.ruby-forum.com/u/wpwood)\
**Post date:** [April 4, 2007, 9:38pm UTC](https://www.ruby-forum.com/t/deploying-rails-app-in-subdomains-of-rails-app/91120/1 "2007-04-04T21:38:02Z")

</div>

Hi,

I’ve got a Rails app deployed at [www.main-domain.com](http://www.main-domain.com). I need to deploy  
copies of that app to subdomains like [sub1.main-domain.com](http://sub1.main-domain.com),  
[sub2.main-domain.com](http://sub2.main-domain.com), etc. Each subdomain could use the same app code,  
but each _must_ have it’s own database. (They also need their own  
images, stylesheets, etc.) None of the examples I’ve been able to  
Google up have that characteristic. They all assume a shared database  
with the subdomain’s data being filtered in the model. I would really  
appreciate any thoughts / experience / pointers to stuff I’ve missed in  
my Googling that might put me on the right track re: how to deploy this.

Thanks,  
Bill
