Perl Dancer on Apache server using Plack::Runner

944 views Asked by At

I have a Perl Dancer web app which I would like to run on an apache server (on centos 6). I put at the webapp's rootdir a sym link (index.html) to the public/dispatch.cgi script which uses the Pluck::Runner module.

The problem is when loading the page, it can't find a needed files (such as the sqlite file), in fact the routing is messed up since it looks for routing at $appname/index.pl/blabla... instead of $appname/blabla...

I think some kind of apache directive or rule is needed here but I don't these well enough.

I hope some one could help me solving this issue.

Thanks in advanced. Roy.

1

There are 1 answers

0
smartmeta On

It would help if you would provide your apache (vhost) configuration.

You should read the section 'Running as a cgi-script (or fast-cgi)' of Dancer deployment, because that document presents a lot differnt ways to deploy your Dancer application.

I like to use behind Apache as proxy. In the Perl Advent Calender 2010 you find a description how to do that.

Starman is fast for the dynamic part and apache perfect for static files and routing.