Merge "dr: Add option to customize base image"
diff --git a/neutron_tempest_plugin/config.py b/neutron_tempest_plugin/config.py
index 23757c1..7c4c0dd 100644
--- a/neutron_tempest_plugin/config.py
+++ b/neutron_tempest_plugin/config.py
@@ -248,6 +248,21 @@
CONF.register_group(taas_group)
CONF.register_opts(TaasGroup, group="taas")
+
+DynamicRoutingGroup = [
+ cfg.StrOpt('base_image',
+ default='quay.io/nf-core/ubuntu:20.04',
+ help=('Base image used to build the image for connectivity '
+ 'check')),
+]
+
+dynamic_routing_group = cfg.OptGroup(
+ name="dynamic_routing",
+ title=("Neutron-Dynamic-Routing Service Options"))
+CONF.register_group(dynamic_routing_group)
+CONF.register_opts(DynamicRoutingGroup, group="dynamic_routing")
+
+
# DNS Integration with an External Service
DnsFeatureGroup = [
cfg.IntOpt(
diff --git a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/base.py b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/base.py
index 25b99d6..3f799bb 100644
--- a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/base.py
+++ b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/base.py
@@ -40,7 +40,6 @@
CHECKTIME_INFO = 60
CHECKTIME_INT = 1
BRIDGE_TYPE = ctn_base.BRIDGE_TYPE_DOCKER
-BASE_NDR_IMAGE = 'quay.io/nf-core/ubuntu:20.04'
def _setup_client_args(auth_provider):
@@ -66,6 +65,7 @@
class BgpSpeakerScenarioTestJSONBase(base.BaseAdminNetworkTest):
+ baseimage = CONF.dynamic_routing.base_image
def setUp(self):
self.addCleanup(self.net_resource_cleanup)
diff --git a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/base.py b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/base.py
index cf1a58e..3719dd6 100644
--- a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/base.py
+++ b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/base.py
@@ -84,7 +84,7 @@
router_id=cls.L_AS.router_id)
cls.dr.set_addr_info(bridge='br-docker-basic', ipv4=cls.public_gw)
# quagga container
- cls.dockerimg = ctn_base.DockerImage(baseimage=base.BASE_NDR_IMAGE)
+ cls.dockerimg = ctn_base.DockerImage(baseimage=cls.baseimage)
cls.q_img = cls.dockerimg.create_quagga(check_exist=True)
cls.images.append(cls.q_img)
for i in range(cls.RAS_MAX):
diff --git a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/test_4byte_asn.py b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/test_4byte_asn.py
index 7ac17d0..1421734 100644
--- a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/test_4byte_asn.py
+++ b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/basic/test_4byte_asn.py
@@ -91,7 +91,7 @@
router_id=cls.L_AS.router_id)
cls.dr.set_addr_info(bridge='br-docker-4byte-asn', ipv4=cls.public_gw)
# quagga container
- cls.dockerimg = ctn_base.DockerImage(baseimage=base.BASE_NDR_IMAGE)
+ cls.dockerimg = ctn_base.DockerImage(baseimage=cls.baseimage)
cls.q_img = cls.dockerimg.create_quagga(check_exist=True)
cls.images.append(cls.q_img)
for i in range(cls.RAS_MAX):
diff --git a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv4/test_ipv4.py b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv4/test_ipv4.py
index ead3a84..57c9018 100644
--- a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv4/test_ipv4.py
+++ b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv4/test_ipv4.py
@@ -91,7 +91,7 @@
router_id=cls.L_AS.router_id)
cls.dr.set_addr_info(bridge='br-docker-ipv4', ipv4=cls.public_gw)
# quagga container
- cls.dockerimg = ctn_base.DockerImage(baseimage=base.BASE_NDR_IMAGE)
+ cls.dockerimg = ctn_base.DockerImage(baseimage=cls.baseimage)
cls.q_img = cls.dockerimg.create_quagga(check_exist=True)
cls.images.append(cls.q_img)
for i in range(cls.RAS_MAX):
diff --git a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv6/test_ipv6.py b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv6/test_ipv6.py
index 29ac079..9bd4c8d 100644
--- a/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv6/test_ipv6.py
+++ b/neutron_tempest_plugin/neutron_dynamic_routing/scenario/ipv6/test_ipv6.py
@@ -91,7 +91,7 @@
router_id=cls.L_AS.router_id)
cls.dr.set_addr_info(bridge='br-docker-ipv6', ipv6=cls.public_gw)
# quagga container
- cls.dockerimg = ctn_base.DockerImage(baseimage=base.BASE_NDR_IMAGE)
+ cls.dockerimg = ctn_base.DockerImage(baseimage=cls.baseimage)
cls.q_img = cls.dockerimg.create_quagga(check_exist=True)
cls.images.append(cls.q_img)
for i in range(cls.RAS_MAX):
diff --git a/releasenotes/notes/dynamic-routing-base-image-12e76a6d85411a6d.yaml b/releasenotes/notes/dynamic-routing-base-image-12e76a6d85411a6d.yaml
new file mode 100644
index 0000000..303e095
--- /dev/null
+++ b/releasenotes/notes/dynamic-routing-base-image-12e76a6d85411a6d.yaml
@@ -0,0 +1,6 @@
+---
+features:
+ - |
+ The new ``[dynamic_routing] base_image`` option has been added. This option
+ allows customizing the reference of the base container image used for
+ connectivity check in dynamic routing plugin tests.