# Rails URL Rewrite help needed

**URL:** <https://www.ruby-forum.com/t/rails-url-rewrite-help-needed/124971>\
**Category:** Rails\
**Created:** [January 4, 2008, 7:19am UTC](https://www.ruby-forum.com/t/rails-url-rewrite-help-needed/124971 "2008-01-04T07:19:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![1978](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/1/ccd318/32.png) [@1978](https://www.ruby-forum.com/u/1978)\
**Post date:** [January 4, 2008, 7:19am UTC](https://www.ruby-forum.com/t/rails-url-rewrite-help-needed/124971/1 "2008-01-04T07:19:09Z")

</div>

Hey guys,

I need some help.

Firstly:

Running Rails 2.0.x  
cPanel Version 11.16.0-RELEASE  
Shared hosting.  
My App is not in public\_html/ but under home/usr/rails\_apps/(rubyapp)

Please tell me how I get my rails app which is using the port eg

[http://www.domain.com:12001/](http://www.domain.com:12001/)

to be accessible without having to have users type the port, or even see  
the port ( the :12001 bit)

Basically, in CPANEL, under ROR you can create a URL rewrite to either a  
subdomain, folder or add on domain, but I cannot get it to work. Once a  
URL is created in CPANEL, I try to view the url but get a 404.

I’d like to be able to access the RoR app through both a subdomain (e.g.  
[myrubyapp.domain.com](http://myrubyapp.domain.com)) and a folder eg ([www.domain.com/arandomfolder/](http://www.domain.com/arandomfolder/))

How do I do this?

Thanks,  
Q
