mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-02 17:48:50 -04:00
Use different colours for each environment
https://www.pivotaltracker.com/story/show/112786779 > There's an emerging convention on admin apps, to have a red strip atop the > page, also to have a different colour for preview environment... so let's > adopt that and see how it feels. Red for prod and gold for preview. This commit adds config so that: - yellow locally - orange on preview and staging - red on live It will not actually work until each AWS environment uses the right config, but can be tested locally by setting the environment variable manually, eg: `export HEADER_COLOUR='#F47738'`
This commit is contained in:
13
config.py
13
config.py
@@ -39,6 +39,8 @@ class Config(object):
|
||||
MAX_CONTENT_LENGTH = 10 * 1024 * 1024 # 10mb
|
||||
UPLOAD_FOLDER = '/tmp'
|
||||
|
||||
HEADER_COLOUR = '#FFBF47' # $yellow
|
||||
|
||||
|
||||
class Development(Config):
|
||||
DEBUG = True
|
||||
@@ -53,10 +55,19 @@ class Test(Development):
|
||||
WTF_CSRF_ENABLED = False
|
||||
|
||||
|
||||
class Live(Config):
|
||||
class Preview(Config):
|
||||
DEBUG = False
|
||||
HTTP_PROTOCOL = 'https'
|
||||
SESSION_COOKIE_SECURE = True
|
||||
HEADER_COLOUR = '#F47738' # $orange
|
||||
|
||||
|
||||
class Staging(Preview):
|
||||
pass
|
||||
|
||||
|
||||
class Live(Staging):
|
||||
HEADER_COLOUR = '#B10E1E' # $red
|
||||
|
||||
|
||||
configs = {
|
||||
|
||||
Reference in New Issue
Block a user