[Catalyst] application broke once installed under other than the web root directory

Charles cshtreck at yahoo.com
Sun Mar 21 17:18:45 GMT 2010


I have finished development of my app using the built in server in the scripts dir. I have installed it and configured apache to let it run under http://myurl.com/myapp . 

The Root.pm index controller get's called and works ( fetches db table data and returns via TT ) when I visit http://myurl.com/myapp. And the debug output is here:

[debug] "GET" request for "/" from "x.x.x.x"
[debug] Path is "/"
[debug] Rendering template "welcome.tt2"

However, when I try to go to http://myurl.com/myapp/foo/bar/2 , I get "page not found", and my debug output shows: 

[debug] "GET" request for "myapp/foo/bar/2" from "x.x.x.x"
[debug] Path is "/"
[debug] Arguments are "myapp/foo/bar/2"

I tried setting __PACKAGE__->config( path => '/myapp'  );
But that doesn't seem to have any effect.

So, I guess I'd like to know how to set the Path above so that it will ( hopefully ) map to the correct controllers. 

This all worked just dandy when run via the server in the scripts dir.

I'm currently running Catalyst 5.80020 and my working apache config contains:

<Perl>
        use lib qw ( /usr/local/myapp/lib );
</Perl>
PerlModule myapp
Alias /myapp "/usr/local/myapp"
<Directory  "/usr/local/myapp">
        SetHandler     perl-script
        PerlResponseHandler    myapp
</Directory>

Any hlp apprec,
-C






      



More information about the Catalyst mailing list