add a json view of the environment to help in debugging (#6125)
This commit is contained in:
parent
373c1f97fd
commit
fc78b3bee4
|
@ -17,4 +17,5 @@ urlpatterns = patterns('',
|
|||
|
||||
url(r'^new-variable-(?P<service>\w+)/(?P<slug>[\w-]+)$',
|
||||
VariableCreateView.as_view(), name='new-variable-service',),
|
||||
url(r'^debug.json$', debug_json, name='debug-json'),
|
||||
)
|
||||
|
|
|
@ -151,3 +151,9 @@ def operational_check_view(request, service, slug, **kwargs):
|
|||
response = HttpResponse(content_type='application/json')
|
||||
json.dump({'operational': object.is_operational()}, response)
|
||||
return response
|
||||
|
||||
|
||||
def debug_json(request):
|
||||
response = HttpResponse(content_type='application/json')
|
||||
json.dump((utils.get_installed_services_dict(),), response, indent=2)
|
||||
return response
|
||||
|
|
Loading…
Reference in New Issue