Handle string value for LAUNCH_INSTANCE_DEFAULTS

During Wallaby cylce, the new default_availablility_zone parameter
was added to LAUNCH_INSTANCE_DEFAULTS[1]. This parameter takes a string
value and the value should be surrounded by ' (or ") when it is put
into local_settings.

This change makes sure that a string value is properly formatted.

[1] fc8603a499fb3302aeb2ebef714420e0fdcbdfef

Change-Id: I1f67c00a737ebea6f965c92a923652632641528d
(cherry picked from commit f20fa4ab83)
(cherry picked from commit 8b9d999bf2)
This commit is contained in:
Takashi Kajinami 2022-01-10 13:50:19 +09:00
parent 8437bc4f34
commit 0d93c965e6
1 changed files with 4 additions and 0 deletions

View File

@ -446,7 +446,11 @@ OPENSTACK_CINDER_FEATURES = {
<%- if ! (@instance_options_real.empty?) -%>
LAUNCH_INSTANCE_DEFAULTS = {
<%- @instance_options_real.sort.each do |opt_name,opt_val| -%>
<%- if opt_val.kind_of?(String) -%>
'<%= opt_name -%>': '<%= opt_val -%>',
<%- else -%>
'<%= opt_name -%>': <%= opt_val.to_s.capitalize -%>,
<%-end-%>
<%-end-%>
}
<%-end-%>