Lightspeed, CPanel, RoR setup

Discussion in 'Ruby/Rails' started by entropie, May 22, 2007.

  1. entropie

    entropie New Member

    Hi,

    I'm a new user. I saw Bob Silva's "under 4 minutes" video and was very impressed. I thought I'd give it a try on my virtual server as I was having trouble configuring RoR to work with Apache and CPanel.

    I've bought a virtual server on VPSland, CentOS Linux 4.4 with CP+ and am having touble configuring RoR to work. I have tried the wiki tutorials for RoR and Lightspeed, Lightspeed and CPanel, as well as following Silva's video.

    Lightspeed works, it serves .html pages that are stored in the web directory root. However, my rails app isn't working, I get 404 whenever I try and hit the app at [IP address]/testapp. [IP address]/testapp/public gives me the rails welcome page.

    I'm running the following:
    • Rails 1.2.3
    • Lightspeed 3.1.1 Standard
    • CPanel 3.1.1

    If anyone has any tips etc I'd really appreciate the help!
  2. mistwang

    mistwang LiteSpeed Staff

    All Rails apps need to be configured through LiteSpeed Web Console, configuration through cPanel may not work.
  3. entropie

    entropie New Member

    mistwang: Thanks, I'm not trying to configure the app through cPanel. I have followed the wiki tutorials, but am having trouble configuring the rails app (through web console). Is there any reason the rails virtual host template method should not work?
  4. mistwang

    mistwang LiteSpeed Staff

    It should work, you need to turn on debug logging and check the error.log.
  5. entropie

    entropie New Member

    ok, i turned on debug logging and checked the logs and found this:

    can not find a matching VHost for [ƒ
  6. entropie

    entropie New Member

    sorry, that didn't work very well. here's what i got:

    Code:
    can not find a matching VHost for [
  7. entropie

    entropie New Member

    sorry, basically it's can not find a matching VHost for *garbage*
  8. entropie

    entropie New Member

    Code:
    2007-05-23 07:41:41.624	DEBUG	[*:80] New connection from 195.229.236.218:60060.
    2007-05-23 07:41:41.624	DEBUG	[*:80] 1 connections accepted!
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] HttpIOLink::handleEvents() events=1!
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] HttpConnection::onReadEx(), state: 0!
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] readToHeaderBuf().
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] Read from client: 765
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] read 765 bytes to header buffer
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] processHeader() return 0, header state: 3.
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] readToHeaderBuf() return 0.
    2007-05-23 07:41:41.624	DEBUG	[207.210.***.***
    User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1.3) Gecko/20070309 Firefox/2.0.0.3
    Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
    Accept-Language: en-us,en;q=0.5
    Accept-Encoding: gzip,deflate
    Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
    Keep-Alive: 300
    Cookie: s_pers=%20s_lastvisit%3D1178995716889%7C1273603716889%3B%20s_vnum%3D1181587716892%2526vn%253D1%7C1181587716892%3B%20s_invisit%3Dtrue%7C1178997549012%3B; PHPSESSID=d81ee7e0e018251351786423a24ecadb; lsws_uid=4leIpi1jgUo%3D; lsws_pass=a%2FgFssc9qqs%3D
    X-Forwarded-For: 86.97.169.169
    Cache-Control: max-stale=0
    Connection: Keep-Alive
    X-BlueCoat-Via: CBF075848BBC073A
    
    cadb; lsws_uid=4leIpi1jgUo%3D; lsws_pass=a%2FgFssc9qqs%3D
    
    ] can not find a matching VHost for [*** garbage ***
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] processNewReq() return 25.
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] HttpConnection::sendHttpError(),code=404 Not Found
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] HttpConnection::flush()!
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] Written to client: 637
    2007-05-23 07:41:41.624	DEBUG	[195.229.236.218:60060-0] HttpConnection::nextRequest()!
    2007-05-23 07:41:45.939	DEBUG	[*:83] New connection from 86.97.169.169:58464.
    2007-05-23 07:41:45.939	DEBUG	[UDS://tmp/lshttpd/admin_php.sock] connection available!
    2007-05-23 07:41:45.939	DEBUG	[UDS://tmp/lshttpd/admin_php.sock] request [86.97.169.169:58464-0#_AdminVHost:lsapi] is assigned with connection!
  9. mistwang

    mistwang LiteSpeed Staff

    Havd you added a vhost to listener mapping?
    Maybe you should instaniate the rails vhost if you have not yet then add the listener to vhost mapping explicitly.

Share This Page