Merge ~gnuoy/ubuntu/+source/ovn-octavia-provider:stable/victoria into ~ubuntu-openstack-dev/ubuntu/+source/ovn-octavia-provider:stable/victoria

Proposed by Liam Young
Status: Merged
Merge reported by: Corey Bryant
Merged at revision: 14ae308149200a2328b35289626198b663ca283c
Proposed branch: ~gnuoy/ubuntu/+source/ovn-octavia-provider:stable/victoria
Merge into: ~ubuntu-openstack-dev/ubuntu/+source/ovn-octavia-provider:stable/victoria
Diff against target: 88 lines (+57/-2)
4 files modified
debian/changelog (+7/-2)
debian/files (+1/-0)
debian/patches/fix-ovn-listeners.patch (+48/-0)
debian/patches/series (+1/-0)
Reviewer Review Type Date Requested Status
Corey Bryant Approve
Review via email: mp+397023@code.launchpad.net

Commit message

Add patch for LP: 1896603

To post a comment you must log in.
Revision history for this message
Corey Bryant (corey.bryant) wrote :

Thanks Liam! Merged. I did refresh the patch with the results of a straight 'git cherry-pick' so that we could pick up the commit message and other details.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/debian/changelog b/debian/changelog
2index 2e153db..f7f03bc 100644
3--- a/debian/changelog
4+++ b/debian/changelog
5@@ -1,8 +1,13 @@
6-ovn-octavia-provider (0.3.0-0ubuntu1.1) UNRELEASED; urgency=medium
7+ovn-octavia-provider (0.3.0-0ubuntu1.3) groovy; urgency=medium
8
9+ [ Corey Bryant ]
10 * d/gbp.conf: Create stable/victoria branch.
11
12- -- Corey Bryant <corey.bryant@canonical.com> Tue, 27 Oct 2020 09:39:16 -0400
13+ [ Liam Young ]
14+ * d/p/fix-ovn-listeners.patch: Correctly process allowed_cidrs option
15+ when creating listeners. LP: #1896603
16+
17+ -- Liam Young <liam.young@canonical.com> Wed, 27 Jan 2021 14:16:45 +0000
18
19 ovn-octavia-provider (0.3.0-0ubuntu1) groovy; urgency=medium
20
21diff --git a/debian/files b/debian/files
22new file mode 100644
23index 0000000..da22be1
24--- /dev/null
25+++ b/debian/files
26@@ -0,0 +1 @@
27+ovn-octavia-provider_0.3.0-0ubuntu1.3_source.buildinfo net optional
28diff --git a/debian/patches/fix-ovn-listeners.patch b/debian/patches/fix-ovn-listeners.patch
29new file mode 100644
30index 0000000..222b25c
31--- /dev/null
32+++ b/debian/patches/fix-ovn-listeners.patch
33@@ -0,0 +1,48 @@
34+--- a/ovn_octavia_provider/driver.py
35++++ b/ovn_octavia_provider/driver.py
36+@@ -58,6 +58,16 @@
37+ user_fault_string=msg,
38+ operator_fault_string=msg)
39+
40++ def _check_for_allowed_cidrs(self, allowed_cidrs):
41++ # TODO(haleyb): add support for this
42++ if isinstance(allowed_cidrs, o_datamodels.UnsetType):
43++ allowed_cidrs = []
44++ if allowed_cidrs:
45++ msg = _('OVN provider does not support allowed_cidrs option')
46++ raise driver_exceptions.UnsupportedOptionError(
47++ user_fault_string=msg,
48++ operator_fault_string=msg)
49++
50+ def loadbalancer_create(self, loadbalancer):
51+ admin_state_up = loadbalancer.admin_state_up
52+ if isinstance(admin_state_up, o_datamodels.UnsetType):
53+@@ -138,12 +148,8 @@
54+
55+ def listener_create(self, listener):
56+ self._check_for_supported_protocols(listener.protocol)
57+- # TODO(haleyb): add support for this
58+- if not isinstance(listener.allowed_cidrs, o_datamodels.UnsetType):
59+- msg = _('OVN provider does not support allowed_cidrs option')
60+- raise driver_exceptions.UnsupportedOptionError(
61+- user_fault_string=msg,
62+- operator_fault_string=msg)
63++ self._check_for_allowed_cidrs(listener.allowed_cidrs)
64++
65+ admin_state_up = listener.admin_state_up
66+ if isinstance(admin_state_up, o_datamodels.UnsetType):
67+ admin_state_up = True
68+@@ -167,12 +173,7 @@
69+ self._ovn_helper.add_request(request)
70+
71+ def listener_update(self, old_listener, new_listener):
72+- # TODO(haleyb): add support for this
73+- if not isinstance(new_listener.allowed_cidrs, o_datamodels.UnsetType):
74+- msg = _('OVN provider does not support allowed_cidrs option')
75+- raise driver_exceptions.UnsupportedOptionError(
76+- user_fault_string=msg,
77+- operator_fault_string=msg)
78++ self._check_for_allowed_cidrs(new_listener.allowed_cidrs)
79+
80+ request_info = {'id': new_listener.listener_id,
81+ 'loadbalancer_id': old_listener.loadbalancer_id,
82diff --git a/debian/patches/series b/debian/patches/series
83new file mode 100644
84index 0000000..06f04b1
85--- /dev/null
86+++ b/debian/patches/series
87@@ -0,0 +1 @@
88+fix-ovn-listeners.patch

Subscribers

People subscribed via source and target branches