add parameter to overwrite/add wsgi process options
Add parameter to apache_wsgi to allow overwrite and/or add additional wsgi process options. This possibility was added to openstacklib with Change-Id: I41914ce3361988d5db1695f09d21209772fdf548 Change-Id: I9f4ca58129a21a61cffbe84ee542ab7e16d2bb19
This commit is contained in:
parent
f28ed8df08
commit
b9088700f5
@ -67,6 +67,14 @@
|
||||
# apache::vhost ssl parameters.
|
||||
# Optional. Default to apache::vhost 'ssl_*' defaults.
|
||||
#
|
||||
# [*custom_wsgi_process_options*]
|
||||
# (optional) gives you the oportunity to add custom process options or to
|
||||
# overwrite the default options for the WSGI main process.
|
||||
# eg. to use a virtual python environment for the WSGI process
|
||||
# you could set it to:
|
||||
# { python-path => '/my/python/virtualenv' }
|
||||
# Defaults to {}
|
||||
#
|
||||
# == Dependencies
|
||||
#
|
||||
# requires Class['apache'] & Class['panko']
|
||||
@ -94,6 +102,7 @@ class panko::wsgi::apache (
|
||||
$wsgi_process_display_name = undef,
|
||||
$threads = $::os_workers,
|
||||
$priority = '10',
|
||||
$custom_wsgi_process_options = {},
|
||||
) {
|
||||
|
||||
include ::panko::deps
|
||||
@ -128,5 +137,6 @@ class panko::wsgi::apache (
|
||||
wsgi_script_dir => $::panko::params::panko_wsgi_script_path,
|
||||
wsgi_script_file => 'app',
|
||||
wsgi_script_source => $::panko::params::panko_wsgi_script_source,
|
||||
custom_wsgi_process_options => $custom_wsgi_process_options,
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
features:
|
||||
- Add parameter to wsgi::apache to allow overwrite
|
||||
and/or add additional wsgi process options.
|
||||
|
@ -34,6 +34,9 @@ describe 'panko::wsgi::apache' do
|
||||
:ssl => false,
|
||||
:wsgi_process_display_name => 'panko',
|
||||
:workers => 8,
|
||||
:custom_wsgi_process_options => {
|
||||
'python_path' => '/my/python/admin/path',
|
||||
},
|
||||
}
|
||||
end
|
||||
it { is_expected.to contain_class('panko::params') }
|
||||
@ -56,6 +59,9 @@ describe 'panko::wsgi::apache' do
|
||||
:wsgi_script_dir => platform_params[:wsgi_script_path],
|
||||
:wsgi_script_file => 'app',
|
||||
:wsgi_script_source => platform_params[:wsgi_script_source],
|
||||
:custom_wsgi_process_options => {
|
||||
'python_path' => '/my/python/admin/path',
|
||||
},
|
||||
)}
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user