Well, I just realized i have lost touch and almost forgotten whatever little programming/scripting i knew and did. Visiting back my perl lessons and trying to script something up on ubuntu with perl and dancer! Just noting the steps here as ive been setting this on multiple machines due to vm crashes or whatever..
Installed
sudo aptitude install apache2 libapache2-mod-perl2
modify the default conf to the below:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www
SetEnv DANCER_ENVIRONMENT "development"
<Directory /var/www>
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<Location />
SetHandler perl-script
PerlHandler Plack::Handler::Apache2
PerlSetVar psgi_app /var/www/bin/app.pl
</Location>
ErrorLog /var/log/apache2/error_log
CustomLog /var/log/apache2/access_log common
</VirtualHost>
I was getting a 500 error, which is when i realised(from earlier) that i did not install the perl modules.
cpanm -i Plack::Handler::Apache2
This is pretty much it to get to apache loading the dancer page.
Next is to get some useful things on there..
Installed
sudo aptitude install apache2 libapache2-mod-perl2
modify the default conf to the below:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www
SetEnv DANCER_ENVIRONMENT "development"
<Directory /var/www>
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<Location />
SetHandler perl-script
PerlHandler Plack::Handler::Apache2
PerlSetVar psgi_app /var/www/bin/app.pl
</Location>
ErrorLog /var/log/apache2/error_log
CustomLog /var/log/apache2/access_log common
</VirtualHost>
I was getting a 500 error, which is when i realised(from earlier) that i did not install the perl modules.
cpanm -i Plack::Handler::Apache2
This is pretty much it to get to apache loading the dancer page.
Next is to get some useful things on there..
Comments