From 7ef245ef7db87df1211067431ea2ad3b2bd44197 Mon Sep 17 00:00:00 2001 From: Luke Short Date: Tue, 11 Aug 2020 10:56:59 -0400 Subject: [PATCH] Expose vhost_custom_fragment It is provided by the Puppet class 'openstacklib::wsgi::apache'. This change exposes it for the Nova API and metadata services. Change-Id: Ifcc1f2c882f7b03ced18f48b54138792a41c3329 Signed-off-by: Luke Short --- manifests/wsgi/apache_api.pp | 7 +++++++ manifests/wsgi/apache_metadata.pp | 7 +++++++ spec/classes/nova_wsgi_apache_api_spec.rb | 2 ++ 3 files changed, 16 insertions(+) diff --git a/manifests/wsgi/apache_api.pp b/manifests/wsgi/apache_api.pp index 27a3055fa..b03b2fb69 100644 --- a/manifests/wsgi/apache_api.pp +++ b/manifests/wsgi/apache_api.pp @@ -90,6 +90,11 @@ # { python-path => '/my/python/virtualenv' } # Defaults to {} # +# [*vhost_custom_fragment*] +# (optional) Passes a string of custom configuration +# directives to be placed at the end of the vhost configuration. +# Defaults to undef. +# # == Dependencies # # requires Class['apache'] & Class['nova'] & Class['nova::api'] @@ -121,6 +126,7 @@ class nova::wsgi::apache_api ( $access_log_format = false, $error_log_file = undef, $custom_wsgi_process_options = {}, + $vhost_custom_fragment = undef, ) { include nova::params @@ -151,6 +157,7 @@ class nova::wsgi::apache_api ( ssl_key => $ssl_key, threads => $threads, user => 'nova', + vhost_custom_fragment => $vhost_custom_fragment, workers => $workers, wsgi_daemon_process => 'nova-api', wsgi_process_display_name => $wsgi_process_display_name, diff --git a/manifests/wsgi/apache_metadata.pp b/manifests/wsgi/apache_metadata.pp index 6ea137cc7..abaf51c03 100644 --- a/manifests/wsgi/apache_metadata.pp +++ b/manifests/wsgi/apache_metadata.pp @@ -76,6 +76,11 @@ # { python-path => '/my/python/virtualenv' } # Defaults to {} # +# [*vhost_custom_fragment*] +# (optional) Passes a string of custom configuration +# directives to be placed at the end of the vhost configuration. +# Defaults to undef. +# # == Dependencies # # requires Class['apache'] & Class['nova'] & Class['nova::metadata'] @@ -108,6 +113,7 @@ class nova::wsgi::apache_metadata ( $access_log_format = false, $error_log_file = undef, $custom_wsgi_process_options = {}, + $vhost_custom_fragment = undef, ) { include nova::params @@ -146,6 +152,7 @@ class nova::wsgi::apache_metadata ( ssl_key => $ssl_key, threads => $threads, user => 'nova', + vhost_custom_fragment => $vhost_custom_fragment, workers => $workers, wsgi_daemon_process => 'nova-metadata', wsgi_process_display_name => $wsgi_process_display_name, diff --git a/spec/classes/nova_wsgi_apache_api_spec.rb b/spec/classes/nova_wsgi_apache_api_spec.rb index d253e70c5..e58a31b34 100644 --- a/spec/classes/nova_wsgi_apache_api_spec.rb +++ b/spec/classes/nova_wsgi_apache_api_spec.rb @@ -55,6 +55,7 @@ describe 'nova::wsgi::apache_api' do :bind_host => '10.42.51.1', :api_port => 12345, :ssl => false, + :vhost_custom_fragment => 'Timeout 99', :wsgi_process_display_name => 'nova-api', :workers => 37, :custom_wsgi_process_options => { @@ -79,6 +80,7 @@ describe 'nova::wsgi::apache_api' do :ssl => false, :threads => 1, :user => 'nova', + :vhost_custom_fragment => 'Timeout 99', :workers => 37, :wsgi_daemon_process => 'nova-api', :wsgi_process_display_name => 'nova-api',