Skip to content

Commit

Permalink
update ADMINS django setting with env support (#1280)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikkonie committed Sep 18, 2023
1 parent b6acc87 commit 74e96ea
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Changed

- **General**
- Refactor and cleanup permission tests (#1267)
- Enable setting ``ADMINS`` Django setting via env (#1280)
- **Timeline**
- Update column width and responsiveness handling (#1721)
- View icon display for site views (#1720)
Expand Down
9 changes: 8 additions & 1 deletion config/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,14 @@

# MANAGER CONFIGURATION
# ------------------------------------------------------------------------------
ADMINS = [("""Admin User""", '[email protected]')]
# Provide ADMINS as: Name:email,Name:email
ADMINS = [
x.split(':')
for x in env.list(
'ADMINS',
default=['Admin:[email protected]', 'Admin2:[email protected]'],
)
]

# See: https://docs.djangoproject.com/en/3.2/ref/settings/#managers
MANAGERS = ADMINS
Expand Down

0 comments on commit 74e96ea

Please sign in to comment.