Creating subdomains

HI All,

I surfed a lot , googled a lot , read/watched railscasts but could not
the solution.

Below is my problem.

  1. I wanted a parent domain This parent domain will have
    subdomains and

The parent domain will have a admin user who has capability to
The subdomains should an a siteadmin user who can edit the site
Each subdomain will have its own home page.

So If i give in browser address bar it should go to a
home page say parent.
If I give it should go to different page.

The site admin of one subdomain should not be able to edit the other

They need to share the same database.

I checked a lot, But could not get the answer.

Please help me to progess i am stuck.


It sounds like what you’re actually after in your application is
what’s called multi-tenancy. Try researching a bit on that topic and
you may find what you need.

Here are a few links to get you started: