From 48e32e12d8e64e3f4cfb8974386035937b0914a7 Mon Sep 17 00:00:00 2001 From: Dobrica Pavlinusic Date: Tue, 3 Apr 2012 01:55:07 +0200 Subject: [PATCH] enviroment config must be at top of file --- misc/plack/koha.psgi | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/misc/plack/koha.psgi b/misc/plack/koha.psgi index 0eb3351f87..e98f32e789 100644 --- a/misc/plack/koha.psgi +++ b/misc/plack/koha.psgi @@ -5,6 +5,12 @@ use lib qw( ./lib ); use Plack::Middleware::Debug; use Plack::App::Directory; +# change configuration from startup script below: + +$ENV{PROFILE_PER_PAGE} = 1; # reset persistant and profile counters after each page, like CGI +$ENV{PLACK_DEBUG} = 1; # toggle debugging +$ENV{MEMCACHED_SERVERS} = ""; # disable memcache + use C4::Context; use C4::Languages; use C4::Members; @@ -23,8 +29,6 @@ my $watch_size = [ keys %INC ]; -$ENV{PROFILE_PER_PAGE} = 1; # used by plack to reset after each page, like CGI - my $app=Plack::App::CGIBin->new(root => $ENV{INTRANETDIR} || $ENV{OPACDIR}); builder { @@ -32,7 +36,7 @@ builder { enable_if { $ENV{PLACK_DEBUG} } 'Debug', panels => [ qw(Koha Persistant), qw(Environment Response Timer Memory), - [ 'Profiler::NYTProf', exclude => [qw(.*\.css .*\.png .*\.ico .*\.js .*\.gif)] ], +# [ 'Profiler::NYTProf', exclude => [qw(.*\.css .*\.png .*\.ico .*\.js .*\.gif)] ], # [ 'DBITrace', level => 1 ], # a LOT of fine-graded SQL trace [ 'DBIProfile', profile => 2 ], # [ 'Devel::Size', for => $watch_size ], -- 2.20.1