Merge "octavia-controller: Convert list values for ListOpts"

This commit is contained in:
Zuul 2021-07-20 18:05:01 +00:00 committed by Gerrit Code Review
commit 7de30ea088
2 changed files with 13 additions and 13 deletions

View File

@ -34,7 +34,7 @@
# #
# [*amp_boot_network_list*] # [*amp_boot_network_list*]
# List of networks to attach to Amphorae. # List of networks to attach to Amphorae.
# Defaults to [] # Defaults to $::os_service_default
# #
# [*loadbalancer_topology*] # [*loadbalancer_topology*]
# (optional) Load balancer topology configuration # (optional) Load balancer topology configuration
@ -185,7 +185,7 @@ class octavia::controller (
$amp_image_tag = $::os_service_default, $amp_image_tag = $::os_service_default,
$amp_image_owner_id = $::os_service_default, $amp_image_owner_id = $::os_service_default,
$amp_secgroup_list = $::os_service_default, $amp_secgroup_list = $::os_service_default,
$amp_boot_network_list = [], $amp_boot_network_list = $::os_service_default,
$loadbalancer_topology = $::os_service_default, $loadbalancer_topology = $::os_service_default,
$amphora_driver = $::os_service_default, $amphora_driver = $::os_service_default,
$compute_driver = $::os_service_default, $compute_driver = $::os_service_default,
@ -241,8 +241,8 @@ class octavia::controller (
'controller_worker/amp_flavor_id' : value => $amp_flavor_id; 'controller_worker/amp_flavor_id' : value => $amp_flavor_id;
'controller_worker/amp_image_tag' : value => $amp_image_tag; 'controller_worker/amp_image_tag' : value => $amp_image_tag;
'controller_worker/amp_image_owner_id' : value => $amp_image_owner_id; 'controller_worker/amp_image_owner_id' : value => $amp_image_owner_id;
'controller_worker/amp_secgroup_list' : value => $amp_secgroup_list; 'controller_worker/amp_secgroup_list' : value => join(any2array($amp_secgroup_list), ',');
'controller_worker/amp_boot_network_list' : value => $amp_boot_network_list; 'controller_worker/amp_boot_network_list' : value => join(any2array($amp_boot_network_list), ',');
'controller_worker/loadbalancer_topology' : value => $loadbalancer_topology; 'controller_worker/loadbalancer_topology' : value => $loadbalancer_topology;
'controller_worker/amphora_driver' : value => $amphora_driver; 'controller_worker/amphora_driver' : value => $amphora_driver;
'controller_worker/compute_driver' : value => $compute_driver; 'controller_worker/compute_driver' : value => $compute_driver;
@ -253,17 +253,17 @@ class octavia::controller (
'haproxy_amphora/timeout_member_connect' : value => $timeout_member_connect; 'haproxy_amphora/timeout_member_connect' : value => $timeout_member_connect;
'haproxy_amphora/timeout_member_data' : value => $timeout_member_data; 'haproxy_amphora/timeout_member_data' : value => $timeout_member_data;
'haproxy_amphora/timeout_tcp_inspect' : value => $timeout_tcp_inspect; 'haproxy_amphora/timeout_tcp_inspect' : value => $timeout_tcp_inspect;
'health_manager/controller_ip_port_list' : value => $controller_ip_port_list; 'health_manager/controller_ip_port_list' : value => join(any2array($controller_ip_port_list), ',');
'haproxy_amphora/connection_max_retries' : value => $connection_max_retries; 'haproxy_amphora/connection_max_retries' : value => $connection_max_retries;
'haproxy_amphora/connection_retry_interval' : value => $connection_retry_interval; 'haproxy_amphora/connection_retry_interval' : value => $connection_retry_interval;
'haproxy_amphora/connection_logging' : value => $connection_logging; 'haproxy_amphora/connection_logging' : value => $connection_logging;
'haproxy_amphora/build_rate_limit' : value => $build_rate_limit; 'haproxy_amphora/build_rate_limit' : value => $build_rate_limit;
'haproxy_amphora/build_active_retries' : value => $build_active_retries; 'haproxy_amphora/build_active_retries' : value => $build_active_retries;
'networking/port_detach_timeout' : value => $port_detach_timeout; 'networking/port_detach_timeout' : value => $port_detach_timeout;
'amphora_agent/admin_log_targets' : value => $admin_log_targets; 'amphora_agent/admin_log_targets' : value => join(any2array($admin_log_targets), ',');
'amphora_agent/administrative_log_facility' : value => $administrative_log_facility; 'amphora_agent/administrative_log_facility' : value => $administrative_log_facility;
'amphora_agent/forward_all_logs' : value => $forward_all_logs; 'amphora_agent/forward_all_logs' : value => $forward_all_logs;
'amphora_agent/tenant_log_targets' : value => $tenant_log_targets; 'amphora_agent/tenant_log_targets' : value => join(any2array($tenant_log_targets), ',');
'amphora_agent/user_log_facility' : value => $user_log_facility; 'amphora_agent/user_log_facility' : value => $user_log_facility;
'haproxy_amphora/user_log_format' : value => $user_log_format; 'haproxy_amphora/user_log_format' : value => $user_log_format;
'amphora_agent/disable_local_log_storage' : value => $disable_local_log_storage; 'amphora_agent/disable_local_log_storage' : value => $disable_local_log_storage;

View File

@ -30,17 +30,17 @@ describe 'octavia::controller' do
:timeout_client_data => 60, :timeout_client_data => 60,
:timeout_member_connect => 5, :timeout_member_connect => 5,
:timeout_member_data => 60, :timeout_member_data => 60,
:controller_ip_port_list => '1.2.3.4:5555,4.3.2.1:5555', :controller_ip_port_list => ['1.2.3.4:5555', '4.3.2.1:5555'],
:connection_max_retries => 240, :connection_max_retries => 240,
:connection_retry_interval => 10, :connection_retry_interval => 10,
:connection_logging => false, :connection_logging => false,
:build_rate_limit => 10, :build_rate_limit => 10,
:build_active_retries => 5, :build_active_retries => 5,
:port_detach_timeout => 15, :port_detach_timeout => 15,
:admin_log_targets => '192.0.2.1:10514,2001:db8:1::10:10514', :admin_log_targets => ['192.0.2.1:10514', '2001:db8:1::10:10514'],
:administrative_log_facility => 2, :administrative_log_facility => 2,
:forward_all_logs => true, :forward_all_logs => true,
:tenant_log_targets => '192.0.2.1:10514,2001:db8:1::10:10514', :tenant_log_targets => ['192.0.2.1:10514', '2001:db8:1::10:10514'],
:user_log_facility => 3, :user_log_facility => 3,
:user_log_format => '{{ project_id }} {{ lb_id }}', :user_log_format => '{{ project_id }} {{ lb_id }}',
:disable_local_log_storage => true, :disable_local_log_storage => true,
@ -59,8 +59,8 @@ describe 'octavia::controller' do
is_expected.to contain_octavia_config('controller_worker/amp_flavor_id').with_value('42') is_expected.to contain_octavia_config('controller_worker/amp_flavor_id').with_value('42')
is_expected.to contain_octavia_config('controller_worker/amp_image_tag').with_value('amphorae1') is_expected.to contain_octavia_config('controller_worker/amp_image_tag').with_value('amphorae1')
is_expected.to contain_octavia_config('controller_worker/amp_image_owner_id').with_value('customowner') is_expected.to contain_octavia_config('controller_worker/amp_image_owner_id').with_value('customowner')
is_expected.to contain_octavia_config('controller_worker/amp_secgroup_list').with_value(['lb-mgmt-sec-grp']) is_expected.to contain_octavia_config('controller_worker/amp_secgroup_list').with_value('lb-mgmt-sec-grp')
is_expected.to contain_octavia_config('controller_worker/amp_boot_network_list').with_value(['lbnet1', 'lbnet2']) is_expected.to contain_octavia_config('controller_worker/amp_boot_network_list').with_value('lbnet1,lbnet2')
is_expected.to contain_octavia_config('controller_worker/loadbalancer_topology').with_value('SINGLE') is_expected.to contain_octavia_config('controller_worker/loadbalancer_topology').with_value('SINGLE')
is_expected.to contain_octavia_config('controller_worker/amphora_driver').with_value('sample_amphora_driver') is_expected.to contain_octavia_config('controller_worker/amphora_driver').with_value('sample_amphora_driver')
is_expected.to contain_octavia_config('controller_worker/compute_driver').with_value('sample_compute_driver') is_expected.to contain_octavia_config('controller_worker/compute_driver').with_value('sample_compute_driver')
@ -101,7 +101,7 @@ describe 'octavia::controller' do
is_expected.to contain_octavia_config('controller_worker/amp_image_tag').with_value('<SERVICE DEFAULT>') is_expected.to contain_octavia_config('controller_worker/amp_image_tag').with_value('<SERVICE DEFAULT>')
is_expected.to contain_octavia_config('controller_worker/amp_image_owner_id').with_value('<SERVICE DEFAULT>') is_expected.to contain_octavia_config('controller_worker/amp_image_owner_id').with_value('<SERVICE DEFAULT>')
is_expected.to contain_octavia_config('controller_worker/amp_secgroup_list').with_value('<SERVICE DEFAULT>') is_expected.to contain_octavia_config('controller_worker/amp_secgroup_list').with_value('<SERVICE DEFAULT>')
is_expected.to contain_octavia_config('controller_worker/amp_boot_network_list').with_value([]) is_expected.to contain_octavia_config('controller_worker/amp_boot_network_list').with_value('<SERVICE DEFAULT>')
is_expected.to contain_octavia_config('controller_worker/loadbalancer_topology').with_value('<SERVICE DEFAULT>') is_expected.to contain_octavia_config('controller_worker/loadbalancer_topology').with_value('<SERVICE DEFAULT>')
is_expected.to contain_octavia_config('controller_worker/amphora_driver').with_value('<SERVICE DEFAULT>') is_expected.to contain_octavia_config('controller_worker/amphora_driver').with_value('<SERVICE DEFAULT>')
is_expected.to contain_octavia_config('controller_worker/compute_driver').with_value('<SERVICE DEFAULT>') is_expected.to contain_octavia_config('controller_worker/compute_driver').with_value('<SERVICE DEFAULT>')