Add missing _driver config items

A working octavia deployment requires configuration of compute, network
and amphora drivers for the octavia worker service.

Change-Id: I422ca9aefbb2a1173f285ddc8271caef8a966a7b
This commit is contained in:
Brent Eagles 2017-01-18 12:11:54 -03:30
parent 99e9b269f1
commit c7b4060c72
3 changed files with 27 additions and 0 deletions

View File

@ -47,6 +47,19 @@
# Possible options are documented in puppet-nova nova_flavor type.
# Defaults to {}.
#
# [*amphora_driver*]
# (optional) Name of driver for communicating with amphorae
# Defaults to 'amphora_haproxy_rest_driver'
#
# [*compute_driver*]
# (optional) Name of driver for managing amphorae VMs
# Defaults to 'compute_nova_driver'
#
# [*network_driver*]
# (optional) Name of network driver for configuring networking
# for amphorae.
# Defaults to 'allowed_address_pairs_driver' (neutron based)
#
class octavia::worker (
$manage_service = true,
$enabled = true,
@ -57,6 +70,9 @@ class octavia::worker (
$loadbalancer_topology = $::os_service_default,
$manage_nova_flavor = true,
$nova_flavor_config = {},
$amphora_driver = 'amphora_haproxy_rest_driver',
$compute_driver = 'compute_nova_driver',
$network_driver = 'allowed_address_pairs_driver'
) inherits octavia::params {
include ::octavia::deps
@ -117,5 +133,8 @@ class octavia::worker (
'controller_worker/amp_image_tag' : value => $amp_image_tag;
'controller_worker/amp_boot_network_list' : value => $amp_boot_network_list;
'controller_worker/loadbalancer_topology' : value => $loadbalancer_topology;
'controller_worker/amphora_driver' : value => $amphora_driver;
'controller_worker/compute_driver' : value => $compute_driver;
'controller_worker/network_driver' : value => $network_driver;
}
}

View File

@ -0,0 +1,5 @@
---
features:
- Added configuration for amphora_driver, compute_driver
and network_driver

View File

@ -42,6 +42,9 @@ describe 'octavia::worker' do
it 'configures worker parameters' do
is_expected.to contain_octavia_config('controller_worker/amp_flavor_id').with_value('65')
is_expected.to contain_octavia_config('controller_worker/amphora_driver').with_value('amphora_haproxy_rest_driver')
is_expected.to contain_octavia_config('controller_worker/compute_driver').with_value('compute_nova_driver')
is_expected.to contain_octavia_config('controller_worker/network_driver').with_value('allowed_address_pairs_driver')
end
it 'deploys nova flavor for octavia worker' do