File tree 1 file changed +8
-2
lines changed
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change
1
+
1
2
use strict;
2
3
use Plack::Builder;
4
+
5
+ use FindBin;
6
+ use lib " $FindBin::Bin /lib" ;
7
+
3
8
use WebGUI::Paths -inc;
4
9
use WebGUI::Config;
5
10
use WebGUI::Fork;
@@ -12,14 +17,15 @@ WebGUI::Fork->init();
12
17
13
18
builder {
14
19
my $first_app ;
20
+ WebGUI::Paths-> siteConfigs or die " no configuration files found" ;
15
21
for my $config_file (WebGUI::Paths-> siteConfigs) {
16
- my $config = WebGUI::Config-> new($config_file );
22
+ my $config = WebGUI::Config-> new($config_file ) or die " failed to log configuration file: $config_file : $! " ;
17
23
my $psgi = $config -> get(' psgiFile' ) || WebGUI::Paths-> defaultPSGI;
18
24
my $app = do {
19
25
# default psgi file uses environment variable to find config file
20
26
local $ENV {WEBGUI_CONFIG } = $config_file ;
21
27
Plack::Util::load_psgi($psgi );
22
- };
28
+ } or die ;
23
29
$first_app ||= $app ;
24
30
my $gateway = $config -> get(' gateway' );
25
31
$gateway =~ s { ^/?} { /} ;
You can’t perform that action at this time.
0 commit comments