-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.py
47 lines (36 loc) · 1023 Bytes
/
config.py
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
from email.mime import base
import os
DEBUG = False
DEBUG_ERROR = False
basedir = os.getcwd()
DB_URI = 'sqlite:///' + os.path.join(basedir, 'data.sqlite')
SQLALCHEMY_DATABASE_URI = DB_URI
SQLALCHEMY_TRACK_MODIFICATIONS = False
SQLALCHEMY_ECHO = False
JSON_AS_ASCII = False
# IMPORTANT! better not to hardcode this key
SECRET_KEY = "WoXiangWangZiYou,WoYaoTanLianAi,WoRiLeGouLe,WoZhaoBuDaoDuiXiang."
MAX_POST_REQUEST = 50
MAX_REPLY_REQUEST = 50
MAIL_SERVER = 'smtp.yeah.net'
MAIL_PORT = 465
MAIL_USERNAME = '[email protected]'
MAIL_PASSWORD = 'UYQACHVLVXIRCDIK'
MAIL_USE_SSL = True
# Path to save user uploaded files
UPLOAD_PATH = os.path.join(basedir, "userdata")
ALLOWED_EXTENTIONS = ['jpg', 'jpeg', 'png', 'gif', 'webp', 'aac', 'mp3', 'wav', 'flac', 'mp4', 'mov', 'avi', 'mpeg', 'amr']
FILE_TYPE = {
'jpg':'IMG',
'jpeg':'IMG',
'png':'IMG',
'gif':'IMG',
'webp':'IMG',
'aac':'AUD',
'mp3':'AUD',
'flac':'AUD',
'amr':'AUD',
'mp4':'VID',
'avi':'VID',
'mpeg':'VID',
}