forked from sergeychernyshev/showslow
-
Notifications
You must be signed in to change notification settings - Fork 0
/
users_config.php
68 lines (51 loc) · 2.15 KB
/
users_config.php
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
<?php
require_once(dirname(__FILE__).'/global.php');
#UserConfig::$DEBUG = true;
UserConfig::$mysql_host = $host;
UserConfig::$mysql_db = $db;
UserConfig::$mysql_user = $user;
UserConfig::$mysql_password = $pass;
UserConfig::$mysql_port = $port;
// TODO - implement accounts and then switch it to true.
UserConfig::$useAccounts = false;
#UserConfig::$enableInvitations = true;
UserConfig::$supportEmailFrom = $supportEmailFrom;
UserConfig::$supportEmailReplyTo = $supportEmailReplyTo;
UserConfig::$SESSION_SECRET = $sessionSecret;
UserConfig::$admins = $instanceAdmins;
UserConfig::$dont_display_activity_for = $instanceAdmins;
UserConfig::$header = dirname(__FILE__).'/header.php';
UserConfig::$footer = dirname(__FILE__).'/footer.php';
UserConfig::$rememberMeDefault = true;
define('SHOWSLOW_ACTIVITY_ADD_URL', 1);
define('SHOWSLOW_ACTIVITY_PAGETEST_START', 2);
define('SHOWSLOW_ACTIVITY_URL_SEARCH', 3);
// array of activities in the system velue is an array of label and value of activity
UserConfig::$activities[SHOWSLOW_ACTIVITY_ADD_URL] = array('Added URL for monitoring', 5);
UserConfig::$activities[SHOWSLOW_ACTIVITY_PAGETEST_START] = array('Started WebPagetest test', 2);
UserConfig::$activities[SHOWSLOW_ACTIVITY_URL_SEARCH] = array('Searched a URL in the list', 1);
if ($facebookAPIKey) {
UserConfig::loadModule('facebook');
new FacebookAuthenticationModule($facebookAPIKey, $facebookSecret);
}
if ($googleOAuthKey && $googleOAuthSecret) {
UserConfig::loadModule('google_oauth');
new GoogleOAuthAuthenticationModule(
$googleOAuthKey,
$googleOAuthSecret
);
}
if ($linkedinOAuthKey && $linkedinOAuthSecret) {
UserConfig::loadModule('linkedin');
new LinkedInAuthenticationModule($linkedinOAuthKey, $linkedinOAuthSecret);
}
if ($twitterOAuthKey && $twitterOAuthSecret) {
UserConfig::loadModule('twitter');
new TwitterAuthenticationModule($twitterOAuthKey, $twitterOAuthSecret);
}
UserConfig::loadModule('usernamepass');
new UsernamePasswordAuthenticationModule();
// Features
// Flot support is now enabled using $enableFlot and this feature flag is not used
define('SHOWSLOW_FLOT_SUPPORT', 1);
new Feature(SHOWSLOW_FLOT_SUPPORT, 'Flot charting library support');