mirror of
https://github.com/ansible/awx.git
synced 2026-03-17 08:57:33 -02:30
Make custom middleware use new style vs old
This commit is contained in:
@@ -93,7 +93,7 @@ INSIGHTS_TRACKING_STATE = False
|
||||
# Use Django-Jenkins if installed. Only run tests for awx.main app.
|
||||
try:
|
||||
import django_jenkins
|
||||
INSTALLED_APPS += (django_jenkins.__name__,) # noqa
|
||||
INSTALLED_APPS += [django_jenkins.__name__,] # noqa
|
||||
PROJECT_APPS = ('awx.main.tests', 'awx.api.tests',)
|
||||
except ImportError:
|
||||
pass
|
||||
@@ -112,7 +112,18 @@ if 'django_jenkins' in INSTALLED_APPS:
|
||||
PEP8_RCFILE = "setup.cfg"
|
||||
PYLINT_RCFILE = ".pylintrc"
|
||||
|
||||
INSTALLED_APPS += ('rest_framework_swagger',)
|
||||
INSTALLED_APPS += [ # NOQA
|
||||
'rest_framework_swagger',
|
||||
'debug_toolbar',
|
||||
]
|
||||
|
||||
MIDDLEWARE += [ # NOQA
|
||||
'debug_toolbar.middleware.DebugToolbarMiddleware',
|
||||
]
|
||||
|
||||
DEBUG_TOOLBAR_CONFIG = {
|
||||
'ENABLE_STACKTRACES' : True,
|
||||
}
|
||||
|
||||
# Configure a default UUID for development only.
|
||||
SYSTEM_UUID = '00000000-0000-0000-0000-000000000000'
|
||||
@@ -162,9 +173,3 @@ except Exception:
|
||||
os.environ['SDB_NOTIFY_HOST'] = os.popen('ip route').read().split(' ')[2]
|
||||
|
||||
WEBSOCKET_ORIGIN_WHITELIST = ['https://localhost:8043', 'https://localhost:3000']
|
||||
|
||||
MIDDLEWARE = [
|
||||
# ...
|
||||
'debug_toolbar.middleware.DebugToolbarMiddleware',
|
||||
# ...
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user