-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathconfig.php
More file actions
32 lines (22 loc) · 828 Bytes
/
config.php
File metadata and controls
32 lines (22 loc) · 828 Bytes
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
<?php
class CONFIG {
public static $TELEGRAM;
public static $MAIL;
public static $SYSDOMAIN;
public static $DELETMAILS;
public static function setup(){
self::$TELEGRAM = array(
'API_TOKEN' => isset( $_ENV['TELEGRAM_API_TOKEN'] ) ? $_ENV['TELEGRAM_API_TOKEN'] : '',
'API_URL' => 'https://api.telegram.org/bot'
);
self::$MAIL = array(
'server' => isset( $_ENV['MAIL_SERVER'] ) ? $_ENV['MAIL_SERVER'] : '{imap.example.com:993/imap/ssl}INBOX',
'user' => isset( $_ENV['MAIL_USER'] ) ? $_ENV['MAIL_USER'] : 'mail@mail.example.com',
'pw' => isset( $_ENV['MAIL_PW'] ) ? $_ENV['MAIL_PW'] : ''
);
self::$SYSDOMAIN = isset( $_ENV['SYSDOMAIN'] ) ? $_ENV['SYSDOMAIN'] : 'mail.example.com';
self::$DELETMAILS = isset( $_ENV['DELETMAILS'] ) && $_ENV['DELETMAILS'] == 'true';
}
}
CONFIG::setup();
?>