Support COMPRESS_ENABLED
The COMPRESS_ENABLED option controls whether the compression should be enabled. This adds support for this option. Change-Id: Ie3e48afc50770b121daacb90d8c70cf241efd330
This commit is contained in:
parent
32c2099414
commit
748e615c78
|
@ -171,6 +171,10 @@
|
|||
# header which links to the value of this setting.
|
||||
# Defaults to undef
|
||||
#
|
||||
# [*compress_enabled*]
|
||||
# (optional) Boolean to enable compression.
|
||||
# Defaults to True
|
||||
#
|
||||
# [*compress_offline*]
|
||||
# (optional) Boolean to enable offline compress of assets.
|
||||
# Defaults to True
|
||||
|
@ -588,6 +592,7 @@ class horizon(
|
|||
$ssl_verify_client = undef,
|
||||
$wsgi_processes = $facts['os_workers'],
|
||||
$wsgi_threads = '1',
|
||||
Boolean $compress_enabled = true,
|
||||
Boolean $compress_offline = true,
|
||||
# TODO(tkajinam) Consider adding more strict validation about key-value
|
||||
Hash $hypervisor_options = {},
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
---
|
||||
features:
|
||||
- |
|
||||
The new ``horizon::compress_enabled`` parameter has been added.
|
|
@ -56,6 +56,7 @@ describe 'horizon' do
|
|||
" 'handlers': ['file'],",
|
||||
'SESSION_TIMEOUT = 3600',
|
||||
'TOKEN_TIMEOUT_MARGIN = 0',
|
||||
'COMPRESS_ENABLED = True',
|
||||
'COMPRESS_OFFLINE = True',
|
||||
"FILE_UPLOAD_TEMP_DIR = '/tmp'",
|
||||
])
|
||||
|
@ -110,6 +111,7 @@ describe 'horizon' do
|
|||
:api_result_limit => 2000,
|
||||
:api_result_page_size => 40,
|
||||
:dropdown_max_items => 123,
|
||||
:compress_enabled => false,
|
||||
:compress_offline => false,
|
||||
:hypervisor_options => {'can_set_mount_point' => false, 'can_set_password' => true },
|
||||
:cinder_options => {'enable_backup' => true },
|
||||
|
@ -215,6 +217,7 @@ describe 'horizon' do
|
|||
" 'handlers': ['console', 'syslog'],",
|
||||
'SESSION_TIMEOUT = 1800',
|
||||
'TOKEN_TIMEOUT_MARGIN = 60',
|
||||
'COMPRESS_ENABLED = False',
|
||||
'COMPRESS_OFFLINE = False',
|
||||
"FILE_UPLOAD_TEMP_DIR = '/var/spool/horizon'",
|
||||
'OVERVIEW_DAYS_RANGE = 1',
|
||||
|
|
|
@ -1044,6 +1044,11 @@ SESSION_TIMEOUT = <%= @session_timeout %>
|
|||
|
||||
TOKEN_TIMEOUT_MARGIN = <%= @token_timeout_margin %>
|
||||
|
||||
# This setting controls whether or not compression is enabled. Disabling
|
||||
# compression makes Horizon considerably slower, but makes it much easier
|
||||
# to debug JS and CSS changes
|
||||
COMPRESS_ENABLED = <%= @compress_enabled.to_s.capitalize %>
|
||||
|
||||
# The Ubuntu package includes pre-compressed JS and compiled CSS to allow
|
||||
# offline compression by default. To enable online compression, install
|
||||
# the python-lesscpy package and disable the following option.
|
||||
|
|
Loading…
Reference in New Issue