Merge lp:~celebdor/charms/trusty/nova-cloud-controller/midonet into lp:~openstack-charmers-archive/charms/trusty/nova-cloud-controller/next

Proposed by Antoni Segura Puimedon
Status: Rejected
Rejected by: James Page
Proposed branch: lp:~celebdor/charms/trusty/nova-cloud-controller/midonet
Merge into: lp:~openstack-charmers-archive/charms/trusty/nova-cloud-controller/next
Diff against target: 219 lines (+73/-11)
8 files modified
config.yaml (+6/-0)
hooks/charmhelpers/contrib/openstack/amulet/utils.py (+1/-1)
hooks/charmhelpers/contrib/openstack/context.py (+30/-4)
hooks/charmhelpers/contrib/openstack/neutron.py (+17/-3)
hooks/charmhelpers/contrib/openstack/templates/ceph.conf (+6/-0)
templates/juno/nova.conf (+7/-1)
templates/kilo/nova.conf (+5/-1)
tests/charmhelpers/contrib/openstack/amulet/utils.py (+1/-1)
To merge this branch: bzr merge lp:~celebdor/charms/trusty/nova-cloud-controller/midonet
Reviewer Review Type Date Requested Status
James Page Needs Fixing
Review via email: mp+273717@code.launchpad.net
To post a comment you must log in.
Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_unit_test #10678 nova-cloud-controller-next for celebdor mp273717
    UNIT OK: passed

Build: http://10.245.162.77:8080/job/charm_unit_test/10678/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_amulet_test #7189 nova-cloud-controller-next for celebdor mp273717
    AMULET FAIL: amulet-test failed

AMULET Results (max last 2 lines):
make: *** [test] Error 1
ERROR:root:Make target returned non-zero.

Full amulet test output: http://paste.ubuntu.com/12706944/
Build: http://10.245.162.77:8080/job/charm_amulet_test/7189/

Revision history for this message
James Page (james-page) :
review: Needs Fixing
Revision history for this message
Antoni Segura Puimedon (celebdor) :
Revision history for this message
James Page (james-page) :

Unmerged revisions

200. By Antoni Segura Puimedon <email address hidden>

Add template and config changes for MidoNet neutron plugin support

199. By Antoni Segura Puimedon <email address hidden>

CH sync for MidoNet support

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'config.yaml'
--- config.yaml 2015-10-02 12:05:06 +0000
+++ config.yaml 2015-10-07 15:52:42 +0000
@@ -420,3 +420,9 @@
420 under the "filter:ratelimit" section as "limits". The syntax for these420 under the "filter:ratelimit" section as "limits". The syntax for these
421 rules is documented at421 rules is documented at
422 http://docs.openstack.org/kilo/config-reference/content/configuring-compute-API.html422 http://docs.openstack.org/kilo/config-reference/content/configuring-compute-API.html
423 shared_secret:
424 default: ""
425 type: string
426 description: |
427 Shared secret between neutron-metadata agent and the nova-api metadata
428 server for signed communication (Used for MidoNet deployments).
423429
=== modified file 'hooks/charmhelpers/contrib/openstack/amulet/utils.py'
--- hooks/charmhelpers/contrib/openstack/amulet/utils.py 2015-09-22 02:07:16 +0000
+++ hooks/charmhelpers/contrib/openstack/amulet/utils.py 2015-10-07 15:52:42 +0000
@@ -752,7 +752,7 @@
752 self.log.debug('SSL is enabled @{}:{} '752 self.log.debug('SSL is enabled @{}:{} '
753 '({})'.format(host, port, unit_name))753 '({})'.format(host, port, unit_name))
754 return True754 return True
755 elif not port and not conf_ssl:755 elif not conf_ssl:
756 self.log.debug('SSL not enabled @{}:{} '756 self.log.debug('SSL not enabled @{}:{} '
757 '({})'.format(host, port, unit_name))757 '({})'.format(host, port, unit_name))
758 return False758 return False
759759
=== modified file 'hooks/charmhelpers/contrib/openstack/context.py'
--- hooks/charmhelpers/contrib/openstack/context.py 2015-09-22 02:45:17 +0000
+++ hooks/charmhelpers/contrib/openstack/context.py 2015-10-07 15:52:42 +0000
@@ -14,6 +14,7 @@
14# You should have received a copy of the GNU Lesser General Public License14# You should have received a copy of the GNU Lesser General Public License
15# along with charm-helpers. If not, see <http://www.gnu.org/licenses/>.15# along with charm-helpers. If not, see <http://www.gnu.org/licenses/>.
1616
17import glob
17import json18import json
18import os19import os
19import re20import re
@@ -951,6 +952,19 @@
951 'config': config}952 'config': config}
952 return ovs_ctxt953 return ovs_ctxt
953954
955 def midonet_ctxt(self):
956 driver = neutron_plugin_attribute(self.plugin, 'driver',
957 self.network_manager)
958 midonet_config = neutron_plugin_attribute(self.plugin, 'config',
959 self.network_manager)
960 mido_ctxt = {'core_plugin': driver,
961 'neutron_plugin': 'midonet',
962 'neutron_security_groups': self.neutron_security_groups,
963 'local_ip': unit_private_ip(),
964 'config': midonet_config}
965
966 return mido_ctxt
967
954 def __call__(self):968 def __call__(self):
955 if self.network_manager not in ['quantum', 'neutron']:969 if self.network_manager not in ['quantum', 'neutron']:
956 return {}970 return {}
@@ -972,6 +986,8 @@
972 ctxt.update(self.nuage_ctxt())986 ctxt.update(self.nuage_ctxt())
973 elif self.plugin == 'plumgrid':987 elif self.plugin == 'plumgrid':
974 ctxt.update(self.pg_ctxt())988 ctxt.update(self.pg_ctxt())
989 elif self.plugin == 'midonet':
990 ctxt.update(self.midonet_ctxt())
975991
976 alchemy_flags = config('neutron-alchemy-flags')992 alchemy_flags = config('neutron-alchemy-flags')
977 if alchemy_flags:993 if alchemy_flags:
@@ -1363,7 +1379,7 @@
1363 normalized.update({port: port for port in resolved1379 normalized.update({port: port for port in resolved
1364 if port in ports})1380 if port in ports})
1365 if resolved:1381 if resolved:
1366 return {bridge: normalized[port] for port, bridge in1382 return {normalized[port]: bridge for port, bridge in
1367 six.iteritems(portmap) if port in normalized.keys()}1383 six.iteritems(portmap) if port in normalized.keys()}
13681384
1369 return None1385 return None
@@ -1374,12 +1390,22 @@
1374 def __call__(self):1390 def __call__(self):
1375 ctxt = {}1391 ctxt = {}
1376 mappings = super(PhyNICMTUContext, self).__call__()1392 mappings = super(PhyNICMTUContext, self).__call__()
1377 if mappings and mappings.values():1393 if mappings and mappings.keys():
1378 ports = mappings.values()1394 ports = sorted(mappings.keys())
1379 napi_settings = NeutronAPIContext()()1395 napi_settings = NeutronAPIContext()()
1380 mtu = napi_settings.get('network_device_mtu')1396 mtu = napi_settings.get('network_device_mtu')
1397 all_ports = set()
1398 # If any of ports is a vlan device, its underlying device must have
1399 # mtu applied first.
1400 for port in ports:
1401 for lport in glob.glob("/sys/class/net/%s/lower_*" % port):
1402 lport = os.path.basename(lport)
1403 all_ports.add(lport.split('_')[1])
1404
1405 all_ports = list(all_ports)
1406 all_ports.extend(ports)
1381 if mtu:1407 if mtu:
1382 ctxt["devs"] = '\\n'.join(ports)1408 ctxt["devs"] = '\\n'.join(all_ports)
1383 ctxt['mtu'] = mtu1409 ctxt['mtu'] = mtu
13841410
1385 return ctxt1411 return ctxt
13861412
=== modified file 'hooks/charmhelpers/contrib/openstack/neutron.py'
--- hooks/charmhelpers/contrib/openstack/neutron.py 2015-09-22 02:45:17 +0000
+++ hooks/charmhelpers/contrib/openstack/neutron.py 2015-10-07 15:52:42 +0000
@@ -209,6 +209,20 @@
209 'server_packages': ['neutron-server',209 'server_packages': ['neutron-server',
210 'neutron-plugin-plumgrid'],210 'neutron-plugin-plumgrid'],
211 'server_services': ['neutron-server']211 'server_services': ['neutron-server']
212 },
213 'midonet': {
214 'config': '/etc/neutron/plugins/midonet/midonet.ini',
215 'driver': 'midonet.neutron.plugin.MidonetPluginV2',
216 'contexts': [
217 context.SharedDBContext(user=config('neutron-database-user'),
218 database=config('neutron-database'),
219 relation_prefix='neutron',
220 ssl_dir=NEUTRON_CONF_DIR)],
221 'services': [],
222 'packages': [[headers_package()] + determine_dkms_package()],
223 'server_packages': ['neutron-server',
224 'python-neutron-plugin-midonet'],
225 'server_services': ['neutron-server']
212 }226 }
213 }227 }
214 if release >= 'icehouse':228 if release >= 'icehouse':
@@ -310,10 +324,10 @@
310def parse_data_port_mappings(mappings, default_bridge='br-data'):324def parse_data_port_mappings(mappings, default_bridge='br-data'):
311 """Parse data port mappings.325 """Parse data port mappings.
312326
313 Mappings must be a space-delimited list of port:bridge mappings.327 Mappings must be a space-delimited list of bridge:port.
314328
315 Returns dict of the form {port:bridge} where port may be an mac address or329 Returns dict of the form {port:bridge} where ports may be mac addresses or
316 interface name.330 interface names.
317 """331 """
318332
319 # NOTE(dosaboy): we use rvalue for key to allow multiple values to be333 # NOTE(dosaboy): we use rvalue for key to allow multiple values to be
320334
=== modified file 'hooks/charmhelpers/contrib/openstack/templates/ceph.conf'
--- hooks/charmhelpers/contrib/openstack/templates/ceph.conf 2015-07-16 20:18:38 +0000
+++ hooks/charmhelpers/contrib/openstack/templates/ceph.conf 2015-10-07 15:52:42 +0000
@@ -13,3 +13,9 @@
13err to syslog = {{ use_syslog }}13err to syslog = {{ use_syslog }}
14clog to syslog = {{ use_syslog }}14clog to syslog = {{ use_syslog }}
1515
16[client]
17{% if rbd_client_cache_settings -%}
18{% for key, value in rbd_client_cache_settings.iteritems() -%}
19{{ key }} = {{ value }}
20{% endfor -%}
21{%- endif %}
16\ No newline at end of file22\ No newline at end of file
1723
=== modified file 'templates/juno/nova.conf'
--- templates/juno/nova.conf 2015-09-17 20:15:37 +0000
+++ templates/juno/nova.conf 2015-10-07 15:52:42 +0000
@@ -60,7 +60,7 @@
60rbd_secret_uuid = {{ rbd_secret_uuid }}60rbd_secret_uuid = {{ rbd_secret_uuid }}
61{% endif -%}61{% endif -%}
6262
63{% if neutron_plugin and neutron_plugin == 'ovs' -%}63{% if neutron_plugin and neutron_plugin in ('ovs', 'midonet') -%}
64libvirt_vif_driver = nova.virt.libvirt.vif.LibvirtGenericVIFDriver64libvirt_vif_driver = nova.virt.libvirt.vif.LibvirtGenericVIFDriver
65libvirt_user_virtio_for_bridges = True65libvirt_user_virtio_for_bridges = True
66{% if neutron_security_groups -%}66{% if neutron_security_groups -%}
@@ -158,6 +158,12 @@
158admin_password = {{ admin_password }}158admin_password = {{ admin_password }}
159{% endif -%}159{% endif -%}
160160
161{% if neutron_plugin and neutron_plugin == 'midonet' -%}
162[neutron]
163service_metadata_proxy = True
164metadata_proxy_shared_secret = {{ shared_secret }}
165{% endif -%}
166
161[osapi_v3]167[osapi_v3]
162enabled=True168enabled=True
163169
164170
=== modified file 'templates/kilo/nova.conf'
--- templates/kilo/nova.conf 2015-09-17 20:15:37 +0000
+++ templates/kilo/nova.conf 2015-10-07 15:52:42 +0000
@@ -53,7 +53,7 @@
53rbd_secret_uuid = {{ rbd_secret_uuid }}53rbd_secret_uuid = {{ rbd_secret_uuid }}
54{% endif -%}54{% endif -%}
5555
56{% if neutron_plugin and neutron_plugin == 'ovs' -%}56{% if neutron_plugin and neutron_plugin in ('ovs', 'midonet') -%}
57libvirt_vif_driver = nova.virt.libvirt.vif.LibvirtGenericVIFDriver57libvirt_vif_driver = nova.virt.libvirt.vif.LibvirtGenericVIFDriver
58libvirt_user_virtio_for_bridges = True58libvirt_user_virtio_for_bridges = True
59{% if neutron_security_groups -%}59{% if neutron_security_groups -%}
@@ -143,6 +143,10 @@
143admin_username = {{ admin_user }}143admin_username = {{ admin_user }}
144admin_password = {{ admin_password }}144admin_password = {{ admin_password }}
145admin_auth_url = {{ auth_protocol }}://{{ auth_host }}:{{ auth_port }}/v2.0145admin_auth_url = {{ auth_protocol }}://{{ auth_host }}:{{ auth_port }}/v2.0
146{% if neutron_plugin and neutron_plugin == 'midonet' -%}
147service_metadata_proxy = True
148metadata_proxy_shared_secret = {{ shared_secret }}
149{% endif -%}
146{% endif -%}150{% endif -%}
147{% endif -%}151{% endif -%}
148152
149153
=== modified file 'tests/charmhelpers/contrib/openstack/amulet/utils.py'
--- tests/charmhelpers/contrib/openstack/amulet/utils.py 2015-09-22 02:07:16 +0000
+++ tests/charmhelpers/contrib/openstack/amulet/utils.py 2015-10-07 15:52:42 +0000
@@ -752,7 +752,7 @@
752 self.log.debug('SSL is enabled @{}:{} '752 self.log.debug('SSL is enabled @{}:{} '
753 '({})'.format(host, port, unit_name))753 '({})'.format(host, port, unit_name))
754 return True754 return True
755 elif not port and not conf_ssl:755 elif not conf_ssl:
756 self.log.debug('SSL not enabled @{}:{} '756 self.log.debug('SSL not enabled @{}:{} '
757 '({})'.format(host, port, unit_name))757 '({})'.format(host, port, unit_name))
758 return False758 return False

Subscribers

People subscribed via source and target branches