# Mapping two host names to the same app

**URL:** <https://www.ruby-forum.com/t/mapping-two-host-names-to-the-same-app/114534>\
**Category:** Rails\
**Created:** [September 14, 2007, 10:22am UTC](https://www.ruby-forum.com/t/mapping-two-host-names-to-the-same-app/114534 "2007-09-14T10:22:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![christophe1](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/b3f665/32.png) [@christophe1](https://www.ruby-forum.com/u/christophe1)\
**Post date:** [September 14, 2007, 10:22am UTC](https://www.ruby-forum.com/t/mapping-two-host-names-to-the-same-app/114534/1 "2007-09-14T10:22:08Z")

</div>

Hi, I wonder if there is any reason to avoid mapping several host names  
to the same rails application in an apache + fcgi configuration (I’m  
thinking about the tmp directory content).

My idea is to detect the host name and render specific views depending  
on its value, eg. [mobile.mysite.com](http://mobile.mysite.com), [www.mysite.com](http://www.mysite.com)

Thanks
