forked from ndrbrt/ssams
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsettings.py
40 lines (28 loc) · 832 Bytes
/
settings.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
import os
BASE_DIR = os.path.abspath(os.path.dirname(__file__))
class Config(object):
"""Base Config class"""
DEBUG = False
TESTING = False
CSRF_ENABLED = True
ARTICLES_PER_PAGE = 1
ARTICLE_BASE_DIR = 'articles/'
FILE_LIST = os.listdir(ARTICLE_BASE_DIR)
SECRET_KEY = 'zsbdxjovgnsenbxdjbgvsenvbxdirutouwaerfvbkjsrgjbv'
class ProductionConfig(Config):
"""Configuration for use in production"""
DEBUG = False
class StagingConfig(Config):
"""Configuration for use in staging"""
DEVELOPMENT = True
DEBUG = True
class DevelopmentConfig(Config):
"""Configuration for use in development"""
DEVELOPMENT = True
DEBUG = True
class TestingConfig(Config):
"""Configuration for use in production"""
TESTING = True
dev = DevelopmentConfig()
staging = StagingConfig()
production = ProductionConfig()