Respect X-Request-Base header coming from a frontend proxy.

This commit is contained in:
Petr Rockai 2013-03-29 22:57:32 +01:00 committed by Eelco Dolstra
parent 5e5b344527
commit 6c0577b226
2 changed files with 6 additions and 0 deletions

View file

@ -13,6 +13,7 @@ with pkgs;
perlPackages.CatalystViewJSON perlPackages.CatalystViewJSON
perlPackages.CatalystViewTT perlPackages.CatalystViewTT
perlPackages.CatalystXScriptServerStarman perlPackages.CatalystXScriptServerStarman
perlPackages.CatalystTraitForRequestProxyBase
perlPackages.CryptRandPasswd perlPackages.CryptRandPasswd
perlPackages.DBDPg perlPackages.DBDPg
perlPackages.DBDSQLite perlPackages.DBDSQLite

View file

@ -3,6 +3,7 @@ package Hydra;
use strict; use strict;
use warnings; use warnings;
use parent 'Catalyst'; use parent 'Catalyst';
use Moose;
use Hydra::Model::DB; use Hydra::Model::DB;
use Catalyst::Runtime '5.70'; use Catalyst::Runtime '5.70';
use Catalyst qw/ConfigLoader use Catalyst qw/ConfigLoader
@ -16,6 +17,8 @@ use Catalyst qw/ConfigLoader
AccessLog AccessLog
Captcha/, Captcha/,
'-Log=warn,fatal,error'; '-Log=warn,fatal,error';
use CatalystX::RoleApplicator;
our $VERSION = '0.01'; our $VERSION = '0.01';
@ -77,6 +80,8 @@ __PACKAGE__->config(
}, },
); );
__PACKAGE__->apply_request_class_roles(qw/Catalyst::TraitFor::Request::ProxyBase/);
__PACKAGE__->setup(); __PACKAGE__->setup();
1; 1;