Convert enabled_provider_agents to proper list format

The driver_agent/enabled_provider_agents is not a MultiOpt but ListOpt
so should look like comma-seprated list. We should not pass puppet list
directly which leaves only the first element written in octavia.conf .

Change-Id: I38cb0015fc88079d26cff779b7d9b99c641a9fa1
This commit is contained in:
Takashi Kajinami 2021-06-29 12:13:24 +09:00
parent 9557c26ad4
commit c868430ae3
2 changed files with 2 additions and 2 deletions

View File

@ -87,6 +87,6 @@ class octavia::driver_agent (
'driver_agent/get_max_processes': value => $get_max_processes;
'driver_agent/max_process_warning_percent': value => $max_process_warning_percent;
'driver_agent/provider_agent_shutdown_timeout': value => $provider_agent_shutdown_timeout;
'driver_agent/enabled_provider_agents': value => $enabled_provider_agents;
'driver_agent/enabled_provider_agents': value => join(any2array($enabled_provider_agents), ',');
}
}

View File

@ -53,7 +53,7 @@ describe 'octavia::driver_agent' do
it { is_expected.to contain_octavia_config('driver_agent/get_max_processes').with_value(10) }
it { is_expected.to contain_octavia_config('driver_agent/max_process_warning_percent').with_value(0.60) }
it { is_expected.to contain_octavia_config('driver_agent/provider_agent_shutdown_timeout').with_value(60) }
it { is_expected.to contain_octavia_config('driver_agent/enabled_provider_agents').with_value(['agent-a', 'agent-b']) }
it { is_expected.to contain_octavia_config('driver_agent/enabled_provider_agents').with_value('agent-a,agent-b') }
end
end