Repository navigation
Expand file tree
/
Copy pathWebConfig.pm
More file actions
72 lines (63 loc) · 1.83 KB
/
Copy pathWebConfig.pm
File metadata and controls
72 lines (63 loc) · 1.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
package WebConfig;
use strict;
use warnings;
use base qw(Exporter);
our @EXPORT = qw ( CSS_PATH TMPL_PATH JS_PATH IMAGES HMTL_PATH CGI_PATH TEMP_PATH TMPL_URL_PATH );
use Conf;
1;
#******************************************************************************
#* GLOBAL CONFIGURATION
#******************************************************************************
#
# File system path configurations.
#
use constant TMPL_PATH => "$Conf::html_base/";
use constant TMPL_URL_PATH => "./Html/";
use constant CFG_PATH => "";
use constant TEMP_PATH => $Conf::temp;
#
# URL path configurations.
#
use constant CGI_PATH => "$Conf::cgi_url/";
use constant CSS_PATH => "$Conf::cgi_url/Html/";
use constant JS_PATH => "$Conf::cgi_url/Html/";
use constant IMAGES => "$Conf::cgi_url/Html/";
use constant HTML_PATH => "$Conf::cgi_url/Html/";
#
# Database settings
#
our $DBNAME = 'WebAppBackend';
our $DBHOST = 'localhost';
our $DBUSER = 'root';
our $DBPWD = '';
our $DBPORT = undef;
our $NODB = undef;
#
# Default values for the web application
#
our $APPLICATION_NAME = 'MG-RAST';
our $APPLICATION_URL = 'http://metagenomics.anl.gov/';
our $ADMIN_EMAIL = 'mg-rast@mcs.anl.gov';
#
# Login dependencies are used to grant login rights
# to web applications a backend depends on.
# rf. to User->grant_login_right
#
our $LOGIN_DEPENDENCIES = { 'RAST' => [ 'SeedViewer', 'MGRAST', 'PRAST' ],
'SeedViewer' => [ 'RAST', 'MGRAST', 'PRAST' ],
'MGRAST' => [ 'RAST', 'SeedViewer', 'PRAST' ],
'PRAST' => [ 'RAST', 'SeedViewer', 'MGRAST' ] };
#
# Method to import local configurations
# from config/WebApplication/BackendName.cfg
#
sub import_local_config {
my $application = shift;
if (ref($application)) {
$application = $application->backend->name();
}
no strict;
{
my $local = CFG_PATH.$application.'.cfg';
}
}