diff --git a/ansibleworks/settings/defaults.py b/ansibleworks/settings/defaults.py
index 5f8a88fe9f..88f3947603 100644
--- a/ansibleworks/settings/defaults.py
+++ b/ansibleworks/settings/defaults.py
@@ -148,6 +148,9 @@ REST_FRAMEWORK = {
),
}
+# If set, serve only minified JS for UI.
+USE_MINIFIED_JS = False
+
# Email address that error messages come from.
SERVER_EMAIL = 'root@localhost'
diff --git a/ansibleworks/settings/production.py b/ansibleworks/settings/production.py
index 41d74684d6..092c296838 100644
--- a/ansibleworks/settings/production.py
+++ b/ansibleworks/settings/production.py
@@ -18,6 +18,9 @@ SECRET_KEY = None
# See https://docs.djangoproject.com/en/dev/ref/settings/#allowed-hosts
ALLOWED_HOSTS = []
+# Production should only use minified JS for UI.
+USE_MINIFIED_JS = True
+
# If a local_settings.py file is present here, use it and ignore the global
# settings. Normally, local settings would only be present during development.
try:
diff --git a/ansibleworks/ui/templates/ui/index.html b/ansibleworks/ui/templates/ui/index.html
index 6662289dcd..e9cf7feb96 100644
--- a/ansibleworks/ui/templates/ui/index.html
+++ b/ansibleworks/ui/templates/ui/index.html
@@ -14,7 +14,7 @@
- {% if 0 and not settings.DEBUG %} {# FIXME: Change to use minified JS once we are building it. #}
+ {% if settings.USE_MINIFIED_JS %} {# FIXME: Change to use minified JS once we are building it. #}
{% else %}