Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
course-discovery
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
course-discovery
Commits
0ef0218c
Commit
0ef0218c
authored
May 04, 2016
by
Clinton Blackburn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated production.py to update JWT_AUTH
parent
712e6a6e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
course_discovery/settings/production.py
+13
-0
No files found.
course_discovery/settings/production.py
View file @
0ef0218c
...
...
@@ -33,9 +33,22 @@ LOGGING['formatters']['syslog_format'] = {
)
}
# Keep track of the names of settings that represent dicts. Instead of overriding the values in base.py,
# the values read from disk should UPDATE the pre-configured dicts.
DICT_UPDATE_KEYS
=
(
'JWT_AUTH'
,)
CONFIG_FILE
=
get_env_setting
(
'COURSE_DISCOVERY_CFG'
)
with
open
(
CONFIG_FILE
)
as
f
:
config_from_yaml
=
yaml
.
load
(
f
)
# Remove the items that should be used to update dicts, and apply them separately rather
# than pumping them into the local vars.
dict_updates
=
{
key
:
config_from_yaml
.
pop
(
key
,
None
)
for
key
in
DICT_UPDATE_KEYS
}
for
key
,
value
in
dict_updates
.
items
():
if
value
:
vars
()[
key
]
.
update
(
value
)
vars
()
.
update
(
config_from_yaml
)
DB_OVERRIDES
=
dict
(
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment