From: Marius Gavrilescu Date: Sun, 25 Jan 2015 20:33:32 +0000 (+0200) Subject: Connect to $ENV{GRUNTMASTER_DSN} if defined X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=ab4514a37ebc941fd4e5aca8be5bd8d110cf74ca;p=gruntmaster-page.git Connect to $ENV{GRUNTMASTER_DSN} if defined --- diff --git a/app.psgi b/app.psgi index a2a62ef..2fcdc00 100644 --- a/app.psgi +++ b/app.psgi @@ -15,7 +15,7 @@ use constant AUTH_TIMEOUT => 5 * 60; use constant ACCESSLOG_FORMAT => '%{X-Forwarded-For}i|%h %u "%r" %>s %b "%{Referer}i" "%{User-agent}i"'; use constant CONTENT_SECURITY_POLICY => q,default-src 'none'; script-src 'self' www.google-analytics.com; style-src 'self'; img-src 'self'; connect-src 'self'; frame-src free.timeanddate.com,; -my $db = Gruntmaster::Data->connect('dbi:Pg:'); +my $db = Gruntmaster::Data->connect($ENV{GRUNTMASTER_DSN} // 'dbi:Pg:'); tie my %auth, 'Tie::Hash::Expire', {expire_seconds => 300};