Version 8, last updated by Titas Norkunas at June 27, 2011 06:30 UTC
Setup Subdomains for Portfolio
This instructions are not required to use Assembla. You should only follow them if you want to enable the Portfolio Manager with Branded subdomains.
1. Option (easy)
1) Add the following lines to your settings_local.yml file
app_domain: .lvh.me
2) Run your server
./rails s
3) Access portfolio via
http://myportfolio.lvh.me:3000
2. Option (difficult)
Required:
- A running version of assembla in your computer
- Mongrel
- Apache 2 (not sure which version you will need, I have Apache/2.2.8)
Steps:
1) Add the following lines to your settings_local.yml file
enable_subdomains: true
app_domain: .myassembla.com
2) Install Passenger
gem install passenger
passenger-install-apache2-module
3) Follow the instructions in the screen to configure Apache with Passenger
4) Add Breakout application to your Apache configuration file (check "Deploying a Ruby on Rails application" from the screen instructions)
This is an example of mine:
<VirtualHost *:80>
ServerName www.myassembla.com
ServerAlias *.myassembla.com
ServerAlias myassembla.com
DocumentRoot /home/sergio/trabajo/workspace/breakout/public
<Directory /home/sergio/trabajo/workspace/breakout/public >
AllowOverride all
Options -MultiViews
</Directory>
</VirtualHost>
Important: Make sure to include the ServerAlias instructions to enable subdomains
5) Restart Apache
6) Add the domain of your server to you hosts file (/etc/hosts)
127.0.0.1 myassembla.com
127.0.0.1 company.myassembla.comĀ
Important: Notice that wildcars like * are not supported in hosts file, so you will have to add the subdomain of the portfolio you want to test
7) Access http://myassembla.com and Enjoy