# Rails on Pair networks

**URL:** <https://www.ruby-forum.com/t/rails-on-pair-networks/58409>\
**Category:** Rails\
**Created:** [April 21, 2006, 10:06am UTC](https://www.ruby-forum.com/t/rails-on-pair-networks/58409 "2006-04-21T10:06:27Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ian\_Beveridge](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/67e7ee/32.png) [@Ian\_Beveridge](https://www.ruby-forum.com/u/Ian_Beveridge)\
**Post date:** [April 21, 2006, 10:06am UTC](https://www.ruby-forum.com/t/rails-on-pair-networks/58409/1 "2006-04-21T10:06:27Z")

</div>

I’ve been looking to play about with Ruby on Rails for a while just to  
see what the fuss is about and now that I have, it looks very  
impressive. Unfortunately I can’t seem to get it to run on my shared web  
server which is run by the hosting company pair networks ([www.pair.com](http://www.pair.com)).

I found the handy guide on the wiki that seemed tailor made for my  
problems and followed the steps…

[http://wiki.rubyonrails.org/rails/pages/RailsOnPairNetworks](http://wiki.rubyonrails.org/rails/pages/RailsOnPairNetworks)

I can create an application, and I can view the “Welcome aboard”  
starting page. When I click on the ‘About your applicationâ??s  
environment’ link however, I get a red box with a 500 error in it rather  
than the nice yellow box full of server info that I was expecting.

In following the wiki guide, I differed from the steps in the following  
ways…

- Software versions. I used ruby 1.8.4, gems 0.8.11 and rails 1.1.2.

- I didn’t set up a new domain. I assumed that everything would work  
fine if I placed the app in a subdirectory of an existing domain. I’m  
not quite sure why the wiki page asks you to set up a whole new domain.  
My app is installed here… [http://kupio.com/railstest/test/public/](http://kupio.com/railstest/test/public/)  
… and I haven’t messed with any URL rewriting stuff.

- I didn’t fix the shebangs at the tops of the ruby scripts since they  
already had the correct path in them.

Things I did/didn’t do are…

- I didn’t set up my database info in config/database.yml. I presumed  
that the test app would work without that, and I’d only need to do that  
once I started coding something proper.

- I chmod +x’d the dispatch cgi scripts.

Initially there were log messages in development.log that indicated an  
error. I have deleted that log file though and it does not seem to be  
getting regenerated. I can’t remember what the error messages were in  
the log. I know that this is unhelpful.

If anyone who understands web server configuration better than me can  
help, I’d very much appreciate that help. Thanks!

- Ian

---

<div class="post-metadata">

**Author:** ![Ian\_Beveridge](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/67e7ee/32.png) [@Ian\_Beveridge](https://www.ruby-forum.com/u/Ian_Beveridge)\
**Post date:** [April 21, 2006, 2:12pm UTC](https://www.ruby-forum.com/t/rails-on-pair-networks/58409/2 "2006-04-21T14:12:47Z")

</div>

Ian Beveridge wrote:

> I’ve been looking to play about with Ruby on Rails for a while just to  
> see what the fuss is about and now that I have, it looks very  
> impressive. Unfortunately I can’t seem to get it to run on my shared web  
> server which is run by the hosting company pair networks ([www.pair.com](http://www.pair.com)).
> 
> I found the handy guide on the wiki that seemed tailor made for my  
> problems and followed the steps…
> 
> [http://wiki.rubyonrails.org/rails/pages/RailsOnPairNetworks](http://wiki.rubyonrails.org/rails/pages/RailsOnPairNetworks)
> 
> I can create an application, and I can view the “Welcome aboard”  
> starting page. When I click on the ‘About your applicationâ??s  
> environment’ link however, I get a red box with a 500 error in it rather  
> than the nice yellow box full of server info that I was expecting.
> 
> In following the wiki guide, I differed from the steps in the following  
> ways…
> 
> - Software versions. I used ruby 1.8.4, gems 0.8.11 and rails 1.1.2.
> 
> - I didn’t set up a new domain. I assumed that everything would work  
> fine if I placed the app in a subdirectory of an existing domain. I’m  
> not quite sure why the wiki page asks you to set up a whole new domain.  
> My app is installed here… [http://kupio.com/railstest/test/public/](http://kupio.com/railstest/test/public/)  
> … and I haven’t messed with any URL rewriting stuff.
> 
> - I didn’t fix the shebangs at the tops of the ruby scripts since they  
> already had the correct path in them.
> 
> Things I did/didn’t do are…
> 
> - I didn’t set up my database info in config/database.yml. I presumed  
> that the test app would work without that, and I’d only need to do that  
> once I started coding something proper.
> 
> - I chmod +x’d the dispatch cgi scripts.
> 
> Initially there were log messages in development.log that indicated an  
> error. I have deleted that log file though and it does not seem to be  
> getting regenerated. I can’t remember what the error messages were in  
> the log. I know that this is unhelpful.
> 
> If anyone who understands web server configuration better than me can  
> help, I’d very much appreciate that help. Thanks!
> 
> - Ian

The ‘About your applictaion environment’ info only displays if it sees  
you connected locally so I don’t think you have any problems there…

If you have you application in a subdirectory there are instructions in  
the .htaccess, it has the following example/instruction

# If your Rails application is accessed via an Alias directive,

# then you MUST also set the RewriteBase in this htaccess file.

# 

# Example:

# Alias /myrailsapp /path/to/myrailsapp/public

# RewriteBase /myrailsapp

In your case it should be

RewriteBase /railstest/test/public/

after that try to navigate to some controller that doesn’t exist, for  
example

[http://kupio.com/railstest/test/public/foo](http://kupio.com/railstest/test/public/foo)

you should get a routing error…

---

<div class="post-metadata">

**Author:** ![Ian\_Beveridge](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/67e7ee/32.png) [@Ian\_Beveridge](https://www.ruby-forum.com/u/Ian_Beveridge)\
**Post date:** [July 14, 2006, 12:19pm UTC](https://www.ruby-forum.com/t/rails-on-pair-networks/58409/3 "2006-07-14T12:19:21Z")

</div>

Hello,

I followed the same wiki page, as well as some info at:

> **[Luke Melia » Ruby on Rails on Pair.com, and on OS X](https://www.lukemelia.com/blog/archives/2005/10/08/ruby-on-rails-on-paircom-and-on-os-x/)**
>
> The personal website of Luke Melia, a vegetarian beach volleyball playing, father, husband and software developer from New York City who attempts to live every day with passion.

> **[Koalan & Surikaten](http://creativi.st/blog/articles/2005/06/10/railing-in-subdirectories)**
>
> Koalan & Surikaten

Everything seems to be fine on my installation:  
ruby --version on command line gives 1.8.4 and points to my  
self-compiled installation at #!/usr/home/\<pair\_user\_name\>/bin/ruby  
I can use irb  
I can “talk” to the Rails installation via script/console (although it’s  
killed after a few seconds of inactivity, but that’s normal)  
The test page shows up nicely.

However, any request that goes via dispatch.cgi fails on an error 500.  
After a lot of testing, it seems that the self-compiled version doesn’t  
work as cgi, even though it does everything on command line (via ssh).

So a simple test script (outside the rails directory):

#!/usr/local/bin/ruby  
puts “lala”

works fine, but

#!/usr/home/\<pair\_user\_name\>/bin/ruby  
puts “lala”

gives an error 500…

Where should I be looking at?  
What additional tests can I perform to find the cause?

Regards,

Pascal Van Hecke

> **[Site not found · DreamHost](http://pascal.vanhecke.info)**
>
> The owner of this domain has not yet uploaded their website.

---

<div class="post-metadata">

**Author:** ![Ian\_Beveridge](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/67e7ee/32.png) [@Ian\_Beveridge](https://www.ruby-forum.com/u/Ian_Beveridge)\
**Post date:** [July 14, 2006, 12:22pm UTC](https://www.ruby-forum.com/t/rails-on-pair-networks/58409/4 "2006-07-14T12:22:31Z")

</div>

> I followed the same wiki page

Sorry, forgot to quote for the sake of the e-mail readers, I meant the  
instructions wiki page at  
[http://wiki.rubyonrails.org/rails/pages/RailsOnPairNetworks](http://wiki.rubyonrails.org/rails/pages/RailsOnPairNetworks)

The entire thread is at  
[http://www.ruby-forum.com/topic/62962](http://www.ruby-forum.com/topic/62962)

Regards,

Pascal Van Hecke

> **[Site not found · DreamHost](http://pascal.vanhecke.info)**
>
> The owner of this domain has not yet uploaded their website.
