Merge "Allow file_upload_temp_dir override"
This commit is contained in:
commit
81125daae5
|
@ -14,10 +14,9 @@ This file is used to list changes made in each version of the openstack-dashboar
|
||||||
* Add sensitive flag to private key and certificate file resources
|
* Add sensitive flag to private key and certificate file resources
|
||||||
* Add hash algorithm option to local_settings
|
* Add hash algorithm option to local_settings
|
||||||
* Update user group for local_settings from root to horizon user group
|
* Update user group for local_settings from root to horizon user group
|
||||||
|
|
||||||
* Bump Chef gem to 11.16
|
* Bump Chef gem to 11.16
|
||||||
|
|
||||||
* Add sensitive flag to local_settings file resource
|
* Add sensitive flag to local_settings file resource
|
||||||
|
* allow override of the temporary directory used for file uploads
|
||||||
|
|
||||||
## 9.1
|
## 9.1
|
||||||
* python_packages database client attributes have been moved to the -common cookbook
|
* python_packages database client attributes have been moved to the -common cookbook
|
||||||
|
|
|
@ -147,6 +147,8 @@ default['openstack']['dashboard']['session_backend'] = 'memcached'
|
||||||
default['openstack']['dashboard']['ssl_offload'] = false
|
default['openstack']['dashboard']['ssl_offload'] = false
|
||||||
default['openstack']['dashboard']['plugins'] = nil
|
default['openstack']['dashboard']['plugins'] = nil
|
||||||
|
|
||||||
|
default['openstack']['dashboard']['file_upload_temp_dir'] = nil
|
||||||
|
|
||||||
default['openstack']['dashboard']['error_log'] = 'openstack-dashboard-error.log'
|
default['openstack']['dashboard']['error_log'] = 'openstack-dashboard-error.log'
|
||||||
default['openstack']['dashboard']['access_log'] = 'openstack-dashboard-access.log'
|
default['openstack']['dashboard']['access_log'] = 'openstack-dashboard-access.log'
|
||||||
|
|
||||||
|
|
|
@ -221,6 +221,19 @@ describe 'openstack-dashboard::server' do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
context 'temp dir override' do
|
||||||
|
context 'temp dir is nil' do
|
||||||
|
it 'does not override temp dir when it is nil' do
|
||||||
|
node.set['openstack']['dashboard']['file_upload_temp_dir'] = nil
|
||||||
|
expect(chef_run).not_to render_file(file.name).with_content(/^FILE_UPLOAD_TEMP_DIR =/)
|
||||||
|
end
|
||||||
|
it 'does override temp dir when it is not nil' do
|
||||||
|
node.set['openstack']['dashboard']['file_upload_temp_dir'] = '/foobar'
|
||||||
|
expect(chef_run).to render_file(file.name).with_content(/^FILE_UPLOAD_TEMP_DIR = "\/foobar"$/)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
context 'ssl settings' do
|
context 'ssl settings' do
|
||||||
context 'use_ssl enabled' do
|
context 'use_ssl enabled' do
|
||||||
before do
|
before do
|
||||||
|
|
|
@ -611,3 +611,7 @@ mod.INSTALLED_APPS += ('<%= p %>', )
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
# define a custom tmp upload directory (override /tmp)
|
||||||
|
<% if node["openstack"]["dashboard"]["file_upload_temp_dir"] %>
|
||||||
|
FILE_UPLOAD_TEMP_DIR = "<%= node["openstack"]["dashboard"]["file_upload_temp_dir"] %>"
|
||||||
|
<% end %>
|
||||||
|
|
Loading…
Reference in New Issue