Rails site and DH stats

Rails site and DH stats

Posted by: anrake
Posted on: 2006-09-09 15:39:00

my site is now running on RoR but when I try to view the DH stats (www.mypage.com/stats) it tries to map to a controller that doesn't exist and I get errors. Is there another way to access DH site stats ?

Re: Rails site and DH stats

Posted by: hbchbc
Posted on: 2006-09-10 08:49:00

do you enable it?
https://panel.dreamhost.com/index.cgi?tree=status.stats&

wink Here are my Hosting Plan Comparision and $97 off DreamHost Promo Code

Re: Rails site and DH stats

Posted by: anrake
Posted on: 2006-09-11 02:51:00

Thanks, but stats are turned on. they were on before with my old site, but since switching to rails I get errors when trying to hit the stats URL. I think it must be because there's no controler called "stats" in the application.

Re: Rails site and DH stats

Posted by: kchrist
Posted on: 2006-09-11 09:53:00

You'll need to add a line to the mod_rewrite rules in public/.htaccess. You should have something like this currently:

RewriteRule ^$ index.html [QSA]
RewriteRule ^([^.]+)$ $1.html [QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ dispatch.cgi [QSA,L]

Add the following line directly above or below the existing RewriteCond line:

RewriteCond %{REQUEST_FILENAME} ^/stats

See the Dreamhost wiki for details.

Re: Rails site and DH stats

Posted by: anrake
Posted on: 2006-09-11 14:54:00

aha ! thank you very much. I tried the wiki but didn't find this page for some reason. anyway, thanks again !

Tags: mypagesite statsrortriesrunningaccessmap