Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8515855
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T05:15:39+00:00 2026-06-11T05:15:39+00:00

Note : i am newbie to ruby on rails and server hosting , i

  • 0

Note : i am newbie to ruby on rails and server hosting , i unable to express my vision as question , please forgive me if i am wrong or correct me.

Hi , i am having an one product developed using ruby on rails , going to host in an dedicated server with 32 GB Ram and 8 Core Server Processor. Each client should have seperate DB and separate rails instance. I am replicating – duplicating code for each client with separate folders and giving different database names and so each serving as an different instance.

For Example:

I am having one primary temp domain

www.product.com

For each client i need to have separate sub domain mapped to same server with same port(80)
but with different rails instance name

www.client1.product.com
www.client2.product.com
www.clientn.product.com

As i know if i start rails instance , each will start at seperate port no’s

client1 with start at port 3001
client2 with start at port 3002
client3 with start at port 3003

What my question is how do i map all the instances with port 80 with appropriate identical sub domains

if i access

www.client4.product.com , i need to get app running in port 3004

Update:

Can anyone please post steps for phusion passenger + Nginx for the above scenario

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T05:15:41+00:00Added an answer on June 11, 2026 at 5:15 am

    Here is a sample example of a minimal server block for nginx + passenger

    server {
            listen 80;
            server_name client1.foobar.com;
            root /var/www/rails/client1/current/public;
    
        passenger_enabled on;
    }
    

    The usual way of configuring nginx is to make a subdirectory “sites-available” where you put a file named “client1.foobar.com” containing this snippet , then make a symbolic link for this file in another subdirectory named “sites-enabled”. Finally you add the following line in you nginx.conf inside the http block

    include /path/to/your/sites-enabled/*;
    

    Do not forget to reload/restart your nginx.

    This way of using symbolic link allows you to easily disable any site you want by deleting the symbolic link without losing your config file.

    You can find some example and more documentation here : http://www.modrails.com/documentation/Users%20guide%20Nginx.html

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm a javascript newbie so please forgive me if this question is really basic.
Note: I had another similar question about how to GZIP data using Ruby's zlib
Very new to javascript here folks, so forgive the newbie question. I want to
I'm newbie in mobile development. cocos2d-x Tutorials says: But please note that linux port
Sorry for the complete newbie question but i'm not having much luck. I've created
NOTE: I'm ultra-newbie on algorithm analysis so don't take any of my affirmations as
Note, this is not a duplicate of .prop() vs .attr() ; that question refers
(Note: This is not a question about what is the best way with code
Note: Not sure if this is the right stack, please tell if I should
NOTE: This is a followup to my question here. I have a program that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.