title: Deploying Rails application to multiple instances
body: <p>I am working on developing a Rails application for my company that we are preparing to deploy for the first time.</p>
  
  <p>Essentially, what I am trying to accomplish is the following:</p>
  
  <ul>
  <li>For each customer, there should be an instance of our Rails application</li>
  <li>Each application should install an Nginx configuration file.</li>
  <li>Each application should have a PostgreSQL database created.</li>
  </ul>
  
  <p>I have been able to find some information on how to do this for one instance on the server, or to deploy to multiple servers, but how would one go about deploying to multiple locations on the same server, while ensuring that the configurations remain correct?</p>
  
  <p>I wouldn't be opposed to creating a shell script to script out <code>cap</code> commands, if necessary.</p>
  
  <p>Thanks!</p>