forked from NinthHeaven/braintest
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.py
21 lines (19 loc) · 906 Bytes
/
config.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# Configurations
import os
basedir = os.path.abspath(os.path.dirname(__file__))
# default config (for production)
class DefaultConfig(object):
DEBUG = False
SECRET_KEY = '~\xa5\xd36;\x8e\x98&\xcc\x00\x93E&\xcen\x91\xe1\xf6v\x19\x87\xd0\xd2\xab'
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL', '').replace('postgres://', 'postgresql://') or 'sqlite:///' + os.path.join(basedir, 'usernames.db')
SQLALCHEMY_TRACK_MODIFACTIONS = False
LOG_TO_STDOUT = os.environ.get('LOG_TO_STDOUT')
MAIL_SERVER = os.environ.get('MAIL_SERVER')
MAIL_PORT = int(os.environ.get('MAIL_PORT') or 25)
MAIL_USE_TLS = os.environ.get('MAIL_USE_TLS') is not None
MAIL_USERNAME = os.environ.get('MAIL_USERNAME')
MAIL_PASSWORD = os.environ.get('MAIL_PASSWORD')
ADMINS = ['[email protected]']
MAX_CONTENT_LENGTH = 1024 * 1024
class devConfig(DefaultConfig):
DEBUG = True