Prepare to update default of <service>::wsgi::apache::ssl

Currently the <service>::wsgi::apache::ssl parameters have inconsistent
default values. Some parameters default to true while the other default
to false.

Based on the following points, false is considered to be the more
reasonable default.
 - Usage of SSL is optional and is not always required
 - There are other methods(like load-balancer) to implement SSL
   termination
 - Enabling SSL doesn't work with the default values currently
   defined, and requires additional parameters like ssl_cert.
 - false is the default value defined in the base implementation in
   puppet-openstacklib.

This change is the preparation to change the default value, and
introduces a warning message to make users aware of the future change.

Change-Id: I91e9506cd1e88cc3dddaa1d2c17f9fa9550e3aec
This commit is contained in:
Takashi Kajinami
2021-11-03 21:02:29 +09:00
parent 04500c7e25
commit d3d7cd9edf
2 changed files with 14 additions and 3 deletions

View File

@@ -102,7 +102,7 @@ class placement::wsgi::apache (
$api_port = 80,
$bind_host = undef,
$path = '/placement',
$ssl = true,
$ssl = undef,
$workers = $::os_workers,
$priority = '10',
$threads = 1,
@@ -130,10 +130,15 @@ class placement::wsgi::apache (
warning('The default path will be changed from /placement to / in a future release.')
}
if $ssl == undef {
warning('Default of the ssl parameter will be changed in a future release')
}
$ssl_real = pick($ssl, true)
include placement::params
include apache
include apache::mod::wsgi
if $ssl {
if $ssl_real {
include apache::mod::ssl
}
@@ -165,7 +170,7 @@ class placement::wsgi::apache (
path => $path,
priority => $priority,
servername => $servername,
ssl => $ssl,
ssl => $ssl_real,
ssl_ca => $ssl_ca,
ssl_cert => $ssl_cert,
ssl_certs_dir => $ssl_certs_dir,

View File

@@ -0,0 +1,6 @@
---
upgrade:
- |
Default value of the ``placement::wsgi::apache::ssl`` parameter will be
changed from ``true`` to ``false`` in a future release. Make sure
the parameter is set to the desired value.