mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 10:00:01 -03:30
Allow settings access from api templates
This commit is contained in:
parent
88128a2e87
commit
3041fce503
@ -202,6 +202,7 @@ class GenericAPIView(generics.GenericAPIView, APIView):
|
||||
'model_verbose_name_plural': unicode(self.model._meta.verbose_name_plural),
|
||||
})
|
||||
d.update({'serializer_fields': self.get_serializer().metadata()})
|
||||
d['settings'] = settings
|
||||
return d
|
||||
|
||||
def metadata(self, request):
|
||||
|
||||
@ -21,7 +21,7 @@ to specify a range of line numbers to retrieve.
|
||||
Use `dark=1` or `dark=0` as a query string parameter to force or disable a
|
||||
dark background.
|
||||
|
||||
Files over 1MB (configurable) will not display in the browser. Use the `txt_download`
|
||||
Files over {{ settings.STDOUT_MAX_BYTES_DISPLAY|filesizeformat }} (configurable) will not display in the browser. Use the `txt_download`
|
||||
format to download the file directly to view it.
|
||||
|
||||
{% include "api/_new_in_awx.md" %}
|
||||
|
||||
@ -567,7 +567,7 @@ FACT_CACHE_PORT = 6564
|
||||
ORG_ADMINS_CAN_SEE_ALL_USERS = True
|
||||
|
||||
# Control when we display stdout and where to store the temporary files for downloading
|
||||
STDOUT_MAX_BYTES_DISPLAY = 1000000
|
||||
STDOUT_MAX_BYTES_DISPLAY = 1048576
|
||||
STDOUT_TEMP_DIR = "/var/lib/awx/"
|
||||
|
||||
# Logging configuration.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user