-
Notifications
You must be signed in to change notification settings - Fork 1
/
config.py
24 lines (16 loc) · 885 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
import os
basedir = os.path.abspath(os.path.dirname(__file__))
class Config:
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or \
'sqlite:///' + os.path.join(basedir, 'app.db')
SQLALCHEMY_TRACK_MODIFICATIONS = False
POSTS_PER_PAGE = os.environ.get('POSTS_PER_PAGE', 10)
SECRET_KEY = os.environ.get('SECRET KEY', os.urandom(16).hex())
LOG_TO_STDOUT = os.environ.get('LOG_TO_STDOUT')
MAIL_SERVER = os.environ.get('MAIL_SERVER', 'smtp.gmail.com')
MAIL_PORT = os.environ.get('MAIL_PORT', 465)
MAIL_USE_SSL = os.environ.get('MAIL_USE_SSL', True)
MAIL_USERNAME = os.environ.get('MAIL_USERNAME', '[email protected]')
MAIL_PASSWORD = os.environ.get('MAIL_PASSWORD', 'your-password')
MAIL_DEFAULT_SENDER = os.environ.get('MAIL_DEFAULT_SENDER', MAIL_USERNAME)
MAIL_ADMIN = os.environ.get('MAIL_ADMIN', MAIL_USERNAME)