Expose tokenserver's allow_new_users setting at top-level server config.
This commit is contained in:
parent
891e30c89c
commit
0ee5588101
@ -5,5 +5,5 @@ simplejson==3.4
|
||||
SQLAlchemy==0.9.4
|
||||
unittest2==0.5.1
|
||||
http://github.com/mozilla-services/mozservices/archive/825cae97e99d1128a07ad8c73dcdc5764562b536.zip
|
||||
https://github.com/mozilla-services/tokenserver/archive/31eaa57797283b5cd4da5a93450638be9059d1dc.zip
|
||||
https://github.com/mozilla-services/tokenserver/archive/02f565379d5af04d23c46d35f3733decd1cab98d.zip
|
||||
http://github.com/mozilla-services/server-syncstorage/archive/1.5.3.zip
|
||||
|
||||
@ -22,3 +22,7 @@ public_url = http://localhost:5000/
|
||||
#
|
||||
# If not specified then the server will generate a temporary one at startup.
|
||||
#secret = INSERT_SECRET_KEY_HERE
|
||||
|
||||
# Set this to "false" to disable new-user signups on the server.
|
||||
# Only request by existing accounts will be honoured.
|
||||
# allow_new_users = false
|
||||
|
||||
@ -52,6 +52,10 @@ def includeme(config):
|
||||
# Default to a single fixed signing secret
|
||||
settings["tokenserver.secrets.backend"] = "mozsvc.secrets.FixedSecrets"
|
||||
settings["tokenserver.secrets.secrets"] = [secret]
|
||||
if "tokenserver.allow_new_users" not in settings:
|
||||
allow_new_users = settings.get("syncserver.allow_new_users")
|
||||
if allow_new_users is not None:
|
||||
settings["tokenserver.allow_new_users"] = allow_new_users
|
||||
if "hawkauth.secrets.backend" not in settings:
|
||||
# Default to the same secrets backend as the tokenserver
|
||||
for key in settings.keys():
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user