auth: Separate development login from main login page.

This allows us to enable EmailAuthBackend by default in development
without cluttering the development login experience.

Fixes #3652.
This commit is contained in:
sinwar
2017-03-18 06:28:45 +05:30
committed by Tim Abbott
parent 4c88b3f5da
commit 397e9c109e
7 changed files with 68 additions and 42 deletions

View File

@@ -17,10 +17,16 @@ if EXTERNAL_HOST is None:
else:
EXTERNAL_HOST = 'localhost:9991'
ALLOWED_HOSTS = ['*']
AUTHENTICATION_BACKENDS = ('zproject.backends.DevAuthBackend',)
# Add some of the below if you're testing other backends
# AUTHENTICATION_BACKENDS = ('zproject.backends.EmailAuthBackend',
# 'zproject.backends.GoogleMobileOauth2Backend',)
# Uncomment extra backends if you want to test with them. Note that
# for Google and GitHub auth you'll need to do some pre-setup.
AUTHENTICATION_BACKENDS = (
'zproject.backends.DevAuthBackend',
'zproject.backends.EmailAuthBackend',
# 'zproject.backends.GitHubAuthBackend',
# 'zproject.backends.GoogleMobileOauth2Backend',
)
EXTERNAL_URI_SCHEME = "http://"
EMAIL_GATEWAY_PATTERN = "%s@" + EXTERNAL_HOST
NOTIFICATION_BOT = "notification-bot@zulip.com"