Merge lp:~springfield-team/charms/precise/nova-cloud-controller/trunk into lp:~openstack-charmers-archive/charms/precise/nova-cloud-controller/trunk

Proposed by Shiv Prasad Rao
Status: Rejected
Rejected by: James Page
Proposed branch: lp:~springfield-team/charms/precise/nova-cloud-controller/trunk
Merge into: lp:~openstack-charmers-archive/charms/precise/nova-cloud-controller/trunk
Diff against target: 673 lines (+490/-3) (has conflicts)
13 files modified
config.yaml (+41/-0)
hooks/charmhelpers/contrib/openstack/context.py (+25/-0)
hooks/charmhelpers/contrib/openstack/neutron.py (+31/-0)
hooks/charmhelpers/contrib/openstack/utils.py (+2/-2)
hooks/nova_cc_context.py (+6/-0)
hooks/nova_cc_hooks.py (+8/-1)
hooks/nova_cc_utils.py (+5/-0)
templates/havana/cisco_plugins.ini (+157/-0)
templates/havana/neutron.conf (+6/-0)
templates/havana/openrc (+15/-0)
templates/icehouse/cisco_plugins.ini (+179/-0)
templates/icehouse/neutron.conf (+6/-0)
templates/icehouse/nova.conf (+9/-0)
Text conflict in config.yaml
Text conflict in hooks/charmhelpers/contrib/openstack/neutron.py
To merge this branch: bzr merge lp:~springfield-team/charms/precise/nova-cloud-controller/trunk
Reviewer Review Type Date Requested Status
James Page Needs Fixing
Marco Ceppi Pending
Csaba TOTH Pending
Review via email: mp+218172@code.launchpad.net

This proposal supersedes a proposal from 2014-05-02.

Description of the change

This merge proposal is prepared to enable N1KV plugin to install with charm logic for nova-cloud-controller.
Similar to ovs and nvp, n1kv (Nexus 1000V) is another layer 2 virtual switch provided by Cisco Nexus 1000V engineering team, which is a host side VM switching fabric building block we call it VEM (Virtual Ethernet Switch). 1+ VEM work in tandem with a VSM (Virtual Switch Module) to form a virtual chassis in a data center.
Please also refer to the VEM/VSM charm and Cisco Nexus1000V related document for its detail.

config.yaml
- added n1kv as a possible value for quantum-plugin
- added n1kv-vsm-username, n1kv-vsm-password, n1kv-vsm-ip to communicate with its supervisor module with (VSM)

hooks/charmhelpers/contrib/openstack/context.py
- Added n1kv related dictionary for context look-up

hooks/charmhelpers/contrib/openstack/neutron.py
- Added n1kv related plugin logic data formation

hooks/nova_cc_hooks.py
- Added copy logic to copy Cisco n1kv template to /root

templates/havana/cisco_plugins.ini
- New file for Cisco Plugin related parameters

templates/havana/neutron.conf
- Added customized system parameters for N1KV plugin to run with

templates/havana/cisco_plugin.ini
- Adding support for PostgreSQL for cisco_plugin.ini

To post a comment you must log in.
Revision history for this message
Marco Ceppi (marcoceppi) wrote : Posted in a previous version of this proposal

Leaving for openstack-charmers, thanks!

review: Abstain
Revision history for this message
ChingWei Chang (cwchang) wrote : Posted in a previous version of this proposal

We have merged with latest Icehouse content which went to charm store first

Revision history for this message
Csaba TOTH (tsabi) wrote : Posted in a previous version of this proposal

On line 320 the mysql is hardcoded. As this charm should support PostgreSQL too i think this is wrongly coded.

review: Needs Fixing
Revision history for this message
Shiv Prasad Rao (shivrao) wrote :

Made change to add support for postgresql

Thanks for the review.

Revision history for this message
James Page (james-page) wrote :

OK _ so I'd like to review the entire springfield charm set from an overall implementation perspective as well but with regards this merge proposal specifically:

1) /root/openrc and associated config.yaml changes

I really don't like this; the nova-cloud-controller gets related to keystone, which give it a username and password so providing it with one external seems just plain wrong;

I *think* this is used by the vxlan-gateway charm to upload its image to glance - but I think we need to review this approach to getting images into glance; this may be better addressed using a helper installed by package (maybe in the vxgw package from the springfield PPA) that gets run from outside the charms, rather than trying todo this from within the charms themselves.

2) Scope of impact on nova-cloud-controller

I think that the change we really need here is the configuration files and support for the nv1k plugin, as for NVP/NSX.

3) charmhelpers first

the changes in hooks/charmhelpers/contrib/ need to be proposed against lp:charm-helpers before landing changes into nova-cloud-controller charm.

review: Needs Fixing
79. By Shiv Prasad Rao

Adding configurable option for n1kv_restrict_policy_profiles

80. By Shiv Prasad Rao

n1kv-config-flags parameter added to add key=value configs to cisco_plugins.ini

81. By Shiv Prasad Rao

Changes for supporting secuirty groups with N1KV

82. By Shiv Prasad Rao

creating seperate n1kv_user_config_flags context variable for n1kv

83. By Shiv Prasad Rao

security group api change for n1kv

84. By Shiv Prasad Rao

Security Groups support for N1kv

85. By Dulanjalie Ganegedara

adding charmhelper support to use --keyserver option for public PPA

Revision history for this message
Shiv Prasad Rao (shivrao) wrote :

Please ignore this merge request. I have submitted a new one here:
https://code.launchpad.net/~springfield-team/charms/trusty/nova-cloud-controller/next/+merge/235182

I can delete this if this causes confusion. (I have kept it for context)

Unmerged revisions

85. By Dulanjalie Ganegedara

adding charmhelper support to use --keyserver option for public PPA

84. By Shiv Prasad Rao

Security Groups support for N1kv

83. By Shiv Prasad Rao

security group api change for n1kv

82. By Shiv Prasad Rao

creating seperate n1kv_user_config_flags context variable for n1kv

81. By Shiv Prasad Rao

Changes for supporting secuirty groups with N1KV

80. By Shiv Prasad Rao

n1kv-config-flags parameter added to add key=value configs to cisco_plugins.ini

79. By Shiv Prasad Rao

Adding configurable option for n1kv_restrict_policy_profiles

78. By Shiv Prasad Rao

Adding support for PostgreSQL for cisco_plugin.ini

77. By Shiv Prasad Rao

Cisco N1KV changes

76. By Shiv Prasad Rao

[niedbalski] fixup unit tests for key management
[niedbalski] Force use of http for key imports

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'config.yaml'
2--- config.yaml 2014-07-29 15:05:01 +0000
3+++ config.yaml 2014-08-01 21:20:18 +0000
4@@ -69,9 +69,14 @@
5 Quantum plugin to use for network management; supports
6 .
7 ovs - OpenvSwitch Plugin
8+<<<<<<< TREE
9 nvp|nsx - Nicira Network Virtualization Platform/
10 VMware NSX Network Virtualization Platform
11 (renamed for Icehouse)
12+=======
13+ nvp - Nicira Network Virtualization Platform
14+ n1kv - Cisco Nexus1000v Network Virtualization Platform
15+>>>>>>> MERGE-SOURCE
16 .
17 This configuration only has context when used with
18 network-manager Quantum|Neutron.
19@@ -163,6 +168,7 @@
20 nvp-l3-uuid:
21 type: string
22 description: |
23+<<<<<<< TREE
24 This is uuid of the default NVP/NSX L3 Gateway Service.
25 # end of NVP/NSX configuration
26 service-guard:
27@@ -184,3 +190,38 @@
28 * shared-db or (pgsql-nova-db, pgsql-neutron-db)
29 * amqp
30 * identity-service
31+=======
32+ This is uuid of the default NVP L3 Gateway Service.
33+ # end of NVP configuration
34+ n1kv-vsm-username:
35+ type: string
36+ default: admin
37+ description: Username to connect to Cisco Nexus1000v VSM
38+ n1kv-vsm-password:
39+ type: string
40+ default: abc123
41+ description: Password to connect to Cisco Nexus1000v VSM
42+ n1kv-vsm-ip:
43+ default: 10.10.10.10
44+ description: IP address to connect to Cisco Nexus1000v VSM
45+ n1kv-restrict-policy-profiles:
46+ type: boolean
47+ default: false
48+ description: |
49+ All tenants will be able to access all policy profiles if disblaed.
50+ If enabled, tenants can access only those policy profiles which are
51+ explicitly assigned to them by admin.
52+ n1kv-config-flags:
53+ default: None
54+ type: string
55+ description: Comma separated list of key=value config flags to be set in cisco_plugins.ini
56+ keystone-usrname:
57+ type: string
58+ default: admin
59+ description: Username to connect to keystone
60+ keystone-password:
61+ type: string
62+ default: openstack
63+ description: Password to connect to keystone
64+
65+>>>>>>> MERGE-SOURCE
66
67=== modified file 'hooks/charmhelpers/contrib/openstack/context.py'
68--- hooks/charmhelpers/contrib/openstack/context.py 2014-05-19 11:38:09 +0000
69+++ hooks/charmhelpers/contrib/openstack/context.py 2014-08-01 21:20:18 +0000
70@@ -541,6 +541,29 @@
71
72 return nvp_ctxt
73
74+ def n1kv_ctxt(self):
75+ driver = neutron_plugin_attribute(self.plugin, 'driver',
76+ self.network_manager)
77+ n1kv_config = neutron_plugin_attribute(self.plugin, 'config',
78+ self.network_manager)
79+ n1kv_user_config_flags = config('n1kv-config-flags')
80+ n1kv_ctxt = {
81+ 'core_plugin': driver,
82+ 'neutron_plugin': 'n1kv',
83+ 'neutron_security_groups': self.neutron_security_groups,
84+ 'local_ip': unit_private_ip(),
85+ 'config': n1kv_config,
86+ 'vsm_ip': config('n1kv-vsm-ip'),
87+ 'vsm_username': config('n1kv-vsm-username'),
88+ 'vsm_password': config('n1kv-vsm-password'),
89+ 'restrict_policy_profiles': config('n1kv-restrict-policy-profiles'),
90+ }
91+ if n1kv_user_config_flags:
92+ flags = config_flags_parser(n1kv_user_config_flags)
93+ n1kv_ctxt['n1kv_user_config_flags'] = flags
94+
95+ return n1kv_ctxt
96+
97 def neutron_ctxt(self):
98 if https():
99 proto = 'https'
100@@ -572,6 +595,8 @@
101 ctxt.update(self.ovs_ctxt())
102 elif self.plugin in ['nvp', 'nsx']:
103 ctxt.update(self.nvp_ctxt())
104+ elif self.plugin == 'n1kv':
105+ ctxt.update(self.n1kv_ctxt())
106
107 alchemy_flags = config('neutron-alchemy-flags')
108 if alchemy_flags:
109
110=== modified file 'hooks/charmhelpers/contrib/openstack/neutron.py'
111--- hooks/charmhelpers/contrib/openstack/neutron.py 2014-05-19 11:38:09 +0000
112+++ hooks/charmhelpers/contrib/openstack/neutron.py 2014-08-01 21:20:18 +0000
113@@ -73,6 +73,20 @@
114 'server_packages': ['quantum-server',
115 'quantum-plugin-nicira'],
116 'server_services': ['quantum-server']
117+ },
118+ 'n1kv': {
119+ 'config': '/etc/quantum/plugins/cisco/cisco_plugins.ini',
120+ 'driver': 'quantum.plugins.cisco.network_plugin.PluginV2',
121+ 'contexts': [
122+ context.SharedDBContext(user=config('neutron-database-user'),
123+ database=config('neutron-database'),
124+ relation_prefix='neutron',
125+ ssl_dir=QUANTUM_CONF_DIR)],
126+ 'services': ['quantum-plugin-cisco'],
127+ 'packages': [['quantum-plugin-cisco']],
128+ 'server_packages': ['quantum-server',
129+ 'quantum-plugin-cisco'],
130+ 'server_services': ['quantum-server']
131 }
132 }
133
134@@ -114,6 +128,7 @@
135 'server_packages': ['neutron-server',
136 'neutron-plugin-nicira'],
137 'server_services': ['neutron-server']
138+<<<<<<< TREE
139 },
140 'nsx': {
141 'config': '/etc/neutron/plugins/vmware/nsx.ini',
142@@ -128,6 +143,22 @@
143 'server_packages': ['neutron-server',
144 'neutron-plugin-vmware'],
145 'server_services': ['neutron-server']
146+=======
147+ },
148+ 'n1kv': {
149+ 'config': '/etc/neutron/plugins/cisco/cisco_plugins.ini',
150+ 'driver': 'neutron.plugins.cisco.network_plugin.PluginV2',
151+ 'contexts': [
152+ context.SharedDBContext(user=config('neutron-database-user'),
153+ database=config('neutron-database'),
154+ relation_prefix='neutron',
155+ ssl_dir=QUANTUM_CONF_DIR)],
156+ 'services': ['neutron-plugin-cisco'],
157+ 'packages': [['neutron-plugin-cisco']],
158+ 'server_packages': ['neutron-server',
159+ 'neutron-plugin-cisco'],
160+ 'server_services': ['neutron-server']
161+>>>>>>> MERGE-SOURCE
162 }
163 }
164 if release >= 'icehouse':
165
166=== modified file 'hooks/charmhelpers/contrib/openstack/utils.py'
167--- hooks/charmhelpers/contrib/openstack/utils.py 2014-05-19 11:38:09 +0000
168+++ hooks/charmhelpers/contrib/openstack/utils.py 2014-08-01 21:20:18 +0000
169@@ -228,8 +228,8 @@
170 with open('/etc/apt/sources.list.d/juju_deb.list', 'w') as f:
171 f.write(DISTRO_PROPOSED % ubuntu_rel)
172 elif rel[:4] == "ppa:":
173- src = rel
174- subprocess.check_call(["add-apt-repository", "-y", src])
175+ src = rel.split(' ')
176+ subprocess.check_call(["add-apt-repository", "-y" ] + src)
177 elif rel[:3] == "deb":
178 l = len(rel.split('|'))
179 if l == 2:
180
181=== modified file 'hooks/nova_cc_context.py'
182--- hooks/nova_cc_context.py 2014-06-17 10:01:21 +0000
183+++ hooks/nova_cc_context.py 2014-08-01 21:20:18 +0000
184@@ -193,6 +193,12 @@
185 ctxt['region'] = config('region')
186 return ctxt
187
188+class OpenrcContext(context.IdentityServiceContext):
189+ def __call__(self):
190+ ctxt = {}
191+ ctxt['os_username'] = config('keystone-usrname')
192+ ctxt['os_password'] = config('keystone-password')
193+ return ctxt
194
195 class NovaPostgresqlDBContext(context.PostgresqlDBContext):
196 interfaces = ['pgsql-nova-db']
197
198=== modified file 'hooks/nova_cc_hooks.py'
199--- hooks/nova_cc_hooks.py 2014-07-29 15:05:01 +0000
200+++ hooks/nova_cc_hooks.py 2014-08-01 21:20:18 +0000
201@@ -4,6 +4,7 @@
202 import shutil
203 import sys
204 import uuid
205+import subprocess
206
207 from subprocess import check_call
208 from urlparse import urlparse
209@@ -84,6 +85,11 @@
210 @hooks.hook()
211 def install():
212 execd_preinstall()
213+ plugin = config('quantum-plugin')
214+ if (plugin == 'n1kv'):
215+ command = "cp templates/havana/openrc /root/"
216+ process = subprocess.Popen(command.split(), stdout=subprocess.PIPE)
217+ process.communicate()[0]
218 configure_installation_source(config('openstack-origin'))
219 apt_update()
220 apt_install(determine_packages(), fatal=True)
221@@ -108,7 +114,8 @@
222 save_script_rc()
223 configure_https()
224 CONFIGS.write_all()
225-
226+ [compute_joined(rid=rid, remote_restart=True)
227+ for rid in relation_ids('cloud-compute')]
228
229 @hooks.hook('amqp-relation-joined')
230 def amqp_joined(relation_id=None):
231
232=== modified file 'hooks/nova_cc_utils.py'
233--- hooks/nova_cc_utils.py 2014-07-29 15:05:01 +0000
234+++ hooks/nova_cc_utils.py 2014-08-01 21:20:18 +0000
235@@ -90,6 +90,7 @@
236 HAPROXY_CONF = '/etc/haproxy/haproxy.cfg'
237 APACHE_CONF = '/etc/apache2/sites-available/openstack_https_frontend'
238 APACHE_24_CONF = '/etc/apache2/sites-available/openstack_https_frontend.conf'
239+OPENRC = '/root/openrc'
240 NEUTRON_DEFAULT = '/etc/default/neutron-server'
241 QUANTUM_DEFAULT = '/etc/default/quantum-server'
242
243@@ -169,6 +170,10 @@
244 'contexts': [nova_cc_context.ApacheSSLContext()],
245 'services': ['apache2'],
246 }),
247+ (OPENRC, {
248+ 'contexts': [nova_cc_context.OpenrcContext(), context.IdentityServiceContext()],
249+ 'services': [],
250+ }),
251 ])
252
253 CA_CERT_PATH = '/usr/local/share/ca-certificates/keystone_juju_ca_cert.crt'
254
255=== added file 'templates/havana/cisco_plugins.ini'
256--- templates/havana/cisco_plugins.ini 1970-01-01 00:00:00 +0000
257+++ templates/havana/cisco_plugins.ini 2014-08-01 21:20:18 +0000
258@@ -0,0 +1,157 @@
259+[cisco_plugins]
260+
261+# (StrOpt) Period-separated module path to the plugin class to use for
262+# the Cisco Nexus switches.
263+#
264+# nexus_plugin = neutron.plugins.cisco.nexus.cisco_nexus_plugin_v2.NexusPlugin
265+
266+# (StrOpt) Period-separated module path to the plugin class to use for
267+# the virtual switches on compute nodes.
268+#
269+# vswitch_plugin = neutron.plugins.openvswitch.ovs_neutron_plugin.OVSNeutronPluginV2
270+
271+
272+[cisco]
273+
274+# (StrOpt) A short prefix to prepend to the VLAN number when creating a
275+# VLAN interface. For example, if an interface is being created for
276+# VLAN 2001 it will be named 'q-2001' using the default prefix.
277+#
278+# vlan_name_prefix = q-
279+# Example: vlan_name_prefix = vnet-
280+
281+# (StrOpt) A short prefix to prepend to the VLAN number when creating a
282+# provider VLAN interface. For example, if an interface is being created
283+# for provider VLAN 3003 it will be named 'p-3003' using the default prefix.
284+#
285+# provider_vlan_name_prefix = p-
286+# Example: provider_vlan_name_prefix = PV-
287+
288+# (BoolOpt) A flag indicating whether Openstack networking should manage the
289+# creation and removal of VLAN interfaces for provider networks on the Nexus
290+# switches. If the flag is set to False then Openstack will not create or
291+# remove VLAN interfaces for provider networks, and the administrator needs
292+# to manage these interfaces manually or by external orchestration.
293+#
294+# provider_vlan_auto_create = True
295+
296+# (BoolOpt) A flag indicating whether Openstack networking should manage
297+# the adding and removing of provider VLANs from trunk ports on the Nexus
298+# switches. If the flag is set to False then Openstack will not add or
299+# remove provider VLANs from trunk ports, and the administrator needs to
300+# manage these operations manually or by external orchestration.
301+#
302+# provider_vlan_auto_trunk = True
303+
304+# (StrOpt) Period-separated module path to the model class to use for
305+# the Cisco neutron plugin.
306+#
307+# model_class = neutron.plugins.cisco.models.virt_phy_sw_v2.VirtualPhysicalSwitchModelV2
308+
309+# (StrOpt) Period-separated module path to the driver class to use for
310+# the Cisco Nexus switches.
311+#
312+# If no value is configured, a fake driver will be used.
313+# nexus_driver = neutron.plugins.cisco.test.nexus.fake_nexus_driver.CiscoNEXUSFakeDriver
314+# With real hardware, use the CiscoNEXUSDriver class:
315+# nexus_driver = neutron.plugins.cisco.nexus.cisco_nexus_network_driver_v2.CiscoNEXUSDriver
316+
317+# (BoolOpt) A flag to enable round robin scheduling of routers for SVI.
318+# svi_round_robin = False
319+
320+
321+# Cisco Nexus Switch configurations.
322+# Each switch to be managed by Openstack Neutron must be configured here.
323+#
324+# Cisco Nexus Switch Format.
325+# [NEXUS_SWITCH:<IP address of switch>]
326+# <hostname>=<port> (1)
327+# ssh_port=<ssh port> (2)
328+# username=<credential username> (3)
329+# password=<credential password> (4)
330+#
331+# (1) For each host connected to a port on the switch, specify the hostname
332+# and the Nexus physical port (interface) it is connected to.
333+# (2) The TCP port for connecting via SSH to manage the switch. This is
334+# port number 22 unless the switch has been configured otherwise.
335+# (3) The username for logging into the switch to manage it.
336+# (4) The password for logging into the switch to manage it.
337+#
338+# Example:
339+# [NEXUS_SWITCH:1.1.1.1]
340+# compute1=1/1
341+# compute2=1/2
342+# ssh_port=22
343+# username=admin
344+# password=mySecretPassword
345+
346+#
347+# N1KV Format.
348+# [N1KV:<IP address of VSM>]
349+# username=<credential username>
350+# password=<credential password>
351+#
352+# Example:
353+# [N1KV:2.2.2.2]
354+# username=admin
355+# password=mySecretPassword
356+
357+[cisco_n1k]
358+
359+# (StrOpt) Specify the name of the integration bridge to which the VIFs are
360+# attached.
361+#
362+integration_bridge = br-int
363+
364+# (StrOpt) Name of the policy profile to be associated with a port when no
365+# policy profile is specified during port creates.
366+#
367+default_policy_profile = default-pp
368+# Example: default_policy_profile = service_profile
369+
370+# (StrOpt) Name of the policy profile to be associated with a port owned by
371+# network node (dhcp, router).
372+#
373+network_node_policy_profile = default-pp
374+# Example: network_node_policy_profile = dhcp_pp
375+
376+# (StrOpt) Name of the network profile to be associated with a network when no
377+# network profile is specified during network creates. Admin should pre-create
378+# a network profile with this name.
379+#
380+# default_network_profile =
381+# Example: default_network_profile = network_pool
382+
383+# (StrOpt) Time in seconds for which the plugin polls the VSM for updates in
384+# policy profiles.
385+#
386+#poll_duration = 10
387+# Example: poll_duration = 180
388+
389+restrict_policy_profiles = {{ restrict_policy_profiles }}
390+# Example: restrict_policy_profiles = False
391+
392+{% if n1kv_user_config_flags -%}
393+{% for key, value in n1kv_user_config_flags.iteritems() -%}
394+{{ key }} = {{ value }}
395+{% endfor -%}
396+{% endif -%}
397+
398+{% include "parts/section-database" %}
399+
400+[CISCO_PLUGINS]
401+vswitch_plugin = neutron.plugins.cisco.n1kv.n1kv_neutron_plugin.N1kvNeutronPluginV2
402+
403+[N1KV:{{ vsm_ip }}]
404+password = {{ vsm_password }}
405+username = {{ vsm_username }}
406+
407+[securitygroup]
408+{% if neutron_security_groups -%}
409+#Firewall driver for realizing neutron security group function.
410+#firewall_driver = neutron.agent.firewall.NoopFirewallDriver
411+firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver
412+enable_security_group = True
413+{% else -%}
414+firewall_driver = neutron.agent.firewall.NoopFirewallDriver
415+{% endif -%}
416
417=== modified file 'templates/havana/neutron.conf'
418--- templates/havana/neutron.conf 2014-04-16 08:25:14 +0000
419+++ templates/havana/neutron.conf 2014-08-01 21:20:18 +0000
420@@ -27,6 +27,12 @@
421
422 {% include "parts/rabbitmq" %}
423
424+{% if neutron_plugin and neutron_plugin == 'n1kv' -%}
425+rpc_backend = neutron.openstack.common.rpc.impl_kombu
426+api_extensions_path = /usr/share/pyshared/neutron/plugins/cisco/extensions
427+network_auto_schedule = False
428+{% endif %}
429+
430 [quotas]
431 quota_driver = neutron.db.quota_db.DbQuotaDriver
432 {% if neutron_security_groups -%}
433
434=== added file 'templates/havana/openrc'
435--- templates/havana/openrc 1970-01-01 00:00:00 +0000
436+++ templates/havana/openrc 2014-08-01 21:20:18 +0000
437@@ -0,0 +1,15 @@
438+#!/bin/sh
439+#This is an example of openrc
440+# READ:http://docs.openstack.org/user-guide/content/cli_openrc.html
441+export OS_NO_CACHE=true
442+export OS_TENANT_NAME=admin
443+export OS_USERNAME={{ os_username }}
444+export OS_PASSWORD={{ os_password }}
445+export OS_AUTH_URL=http://{{ service_host }}:{{ service_port }}/v2.0/
446+export OS_AUTH_STRATEGY=keystone
447+export OS_REGION_NAME=RegionOne
448+export CINDER_ENDPOINT_TYPE=publicURL
449+export GLANCE_ENDPOINT_TYPE=publicURL
450+export KEYSTONE_ENDPOINT_TYPE=publicURL
451+export NOVA_ENDPOINT_TYPE=publicURL
452+export QUANTUM_ENDPOINT_TYPE=publicURL
453
454=== added file 'templates/icehouse/cisco_plugins.ini'
455--- templates/icehouse/cisco_plugins.ini 1970-01-01 00:00:00 +0000
456+++ templates/icehouse/cisco_plugins.ini 2014-08-01 21:20:18 +0000
457@@ -0,0 +1,179 @@
458+[cisco_plugins]
459+
460+# (StrOpt) Period-separated module path to the plugin class to use for
461+# the Cisco Nexus switches.
462+#
463+# nexus_plugin = neutron.plugins.cisco.nexus.cisco_nexus_plugin_v2.NexusPlugin
464+
465+# (StrOpt) Period-separated module path to the plugin class to use for
466+# the virtual switches on compute nodes.
467+#
468+# vswitch_plugin = neutron.plugins.openvswitch.ovs_neutron_plugin.OVSNeutronPluginV2
469+
470+
471+[cisco]
472+
473+# (StrOpt) A short prefix to prepend to the VLAN number when creating a
474+# VLAN interface. For example, if an interface is being created for
475+# VLAN 2001 it will be named 'q-2001' using the default prefix.
476+#
477+# vlan_name_prefix = q-
478+# Example: vlan_name_prefix = vnet-
479+
480+# (StrOpt) A short prefix to prepend to the VLAN number when creating a
481+# provider VLAN interface. For example, if an interface is being created
482+# for provider VLAN 3003 it will be named 'p-3003' using the default prefix.
483+#
484+# provider_vlan_name_prefix = p-
485+# Example: provider_vlan_name_prefix = PV-
486+
487+# (BoolOpt) A flag indicating whether Openstack networking should manage the
488+# creation and removal of VLAN interfaces for provider networks on the Nexus
489+# switches. If the flag is set to False then Openstack will not create or
490+# remove VLAN interfaces for provider networks, and the administrator needs
491+# to manage these interfaces manually or by external orchestration.
492+#
493+# provider_vlan_auto_create = True
494+
495+# (BoolOpt) A flag indicating whether Openstack networking should manage
496+# the adding and removing of provider VLANs from trunk ports on the Nexus
497+# switches. If the flag is set to False then Openstack will not add or
498+# remove provider VLANs from trunk ports, and the administrator needs to
499+# manage these operations manually or by external orchestration.
500+#
501+# provider_vlan_auto_trunk = True
502+
503+# (StrOpt) Period-separated module path to the model class to use for
504+# the Cisco neutron plugin.
505+#
506+# model_class = neutron.plugins.cisco.models.virt_phy_sw_v2.VirtualPhysicalSwitchModelV2
507+
508+# (StrOpt) Period-separated module path to the driver class to use for
509+# the Cisco Nexus switches.
510+#
511+# If no value is configured, a fake driver will be used.
512+# nexus_driver = neutron.plugins.cisco.test.nexus.fake_nexus_driver.CiscoNEXUSFakeDriver
513+# With real hardware, use the CiscoNEXUSDriver class:
514+# nexus_driver = neutron.plugins.cisco.nexus.cisco_nexus_network_driver_v2.CiscoNEXUSDriver
515+
516+# (BoolOpt) A flag to enable round robin scheduling of routers for SVI.
517+# svi_round_robin = False
518+
519+
520+# Cisco Nexus Switch configurations.
521+# Each switch to be managed by Openstack Neutron must be configured here.
522+#
523+# Cisco Nexus Switch Format.
524+# [NEXUS_SWITCH:<IP address of switch>]
525+# <hostname>=<port> (1)
526+# ssh_port=<ssh port> (2)
527+# username=<credential username> (3)
528+# password=<credential password> (4)
529+#
530+# (1) For each host connected to a port on the switch, specify the hostname
531+# and the Nexus physical port (interface) it is connected to.
532+# (2) The TCP port for connecting via SSH to manage the switch. This is
533+# port number 22 unless the switch has been configured otherwise.
534+# (3) The username for logging into the switch to manage it.
535+# (4) The password for logging into the switch to manage it.
536+#
537+# Example:
538+# [NEXUS_SWITCH:1.1.1.1]
539+# compute1=1/1
540+# compute2=1/2
541+# ssh_port=22
542+# username=admin
543+# password=mySecretPassword
544+
545+#
546+# N1KV Format.
547+# [N1KV:<IP address of VSM>]
548+# username=<credential username>
549+# password=<credential password>
550+#
551+# Example:
552+# [N1KV:2.2.2.2]
553+# username=admin
554+# password=mySecretPassword
555+
556+[cisco_n1k]
557+
558+# (StrOpt) Specify the name of the integration bridge to which the VIFs are
559+# attached.
560+#
561+integration_bridge = br-int
562+
563+# (StrOpt) Name of the policy profile to be associated with a port when no
564+# policy profile is specified during port creates.
565+#
566+default_policy_profile = default-pp
567+# Example: default_policy_profile = service_profile
568+
569+# (StrOpt) Name of the policy profile to be associated with a port owned by
570+# network node (dhcp, router).
571+#
572+network_node_policy_profile = default-pp
573+# Example: network_node_policy_profile = dhcp_pp
574+
575+# (StrOpt) Name of the network profile to be associated with a network when no
576+# network profile is specified during network creates. Admin should pre-create
577+# a network profile with this name.
578+#
579+# default_network_profile =
580+# Example: default_network_profile = network_pool
581+
582+# (StrOpt) Time in seconds for which the plugin polls the VSM for updates in
583+# policy profiles.
584+#
585+#poll_duration = 10
586+# Example: poll_duration = 180
587+
588+# (BoolOpt) Specify whether tenants are restricted from accessing all the
589+# policy profiles.
590+# Default value: False, indicating all tenants can access all policy profiles.
591+#
592+# restrict_policy_profiles =
593+# Example: restrict_policy_profiles = False
594+
595+# (IntOpt) Number of threads to use to make HTTP requests to the VSM.
596+#
597+# http_pool_size = 4
598+
599+# (IntOpt) Time in seconds for which the plugin waits for the VSM to respond.
600+#
601+# http_timeout = 30
602+http_timeout = 120
603+
604+
605+# (BoolOpt) Specify whether plugin should attempt to synchronize with the VSM
606+# when neutron is started.
607+# Default value: False, indicating no full sync will be performed.
608+#
609+# enable_sync_on_start = False
610+
611+restrict_policy_profiles = {{ restrict_policy_profiles }}
612+
613+{% if n1kv_user_config_flags -%}
614+{% for key, value in n1kv_user_config_flags.iteritems() -%}
615+{{ key }} = {{ value }}
616+{% endfor -%}
617+{% endif -%}
618+
619+{% include "parts/section-database" %}
620+
621+[CISCO_PLUGINS]
622+vswitch_plugin = neutron.plugins.cisco.n1kv.n1kv_neutron_plugin.N1kvNeutronPluginV2
623+
624+[N1KV:{{ vsm_ip }}]
625+password = {{ vsm_password }}
626+username = {{ vsm_username }}
627+
628+[securitygroup]
629+{% if neutron_security_groups -%}
630+#Firewall driver for realizing neutron security group function.
631+#firewall_driver = neutron.agent.firewall.NoopFirewallDriver
632+firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver
633+enable_security_group = True
634+{% else -%}
635+firewall_driver = neutron.agent.firewall.NoopFirewallDriver
636+{% endif -%}
637
638=== modified file 'templates/icehouse/neutron.conf'
639--- templates/icehouse/neutron.conf 2014-06-17 10:01:21 +0000
640+++ templates/icehouse/neutron.conf 2014-08-01 21:20:18 +0000
641@@ -29,6 +29,12 @@
642
643 {% include "parts/rabbitmq" %}
644
645+{% if neutron_plugin and neutron_plugin == 'n1kv' -%}
646+rpc_backend = neutron.openstack.common.rpc.impl_kombu
647+api_extensions_path = /usr/share/pyshared/neutron/plugins/cisco/extensions
648+network_auto_schedule = False
649+{% endif %}
650+
651 notify_nova_on_port_status_changes = True
652 notify_nova_on_port_data_changes = True
653 nova_url = {{ nova_url }}
654
655=== modified file 'templates/icehouse/nova.conf'
656--- templates/icehouse/nova.conf 2014-04-12 21:25:19 +0000
657+++ templates/icehouse/nova.conf 2014-08-01 21:20:18 +0000
658@@ -58,6 +58,15 @@
659 {% endif -%}
660 {% endif -%}
661
662+{% if neutron_plugin and neutron_plugin == 'n1kv' -%}
663+libvirt_user_virtio_for_bridges = True
664+security_group_api = {{ network_manager }}
665+nova_firewall_driver = nova.virt.firewall.NoopFirewallDriver
666+{% if external_network -%}
667+default_floating_pool = {{ external_network }}
668+{% endif -%}
669+{% endif -%}
670+
671 {% if network_manager_config -%}
672 {% for key, value in network_manager_config.iteritems() -%}
673 {{ key }} = {{ value }}

Subscribers

People subscribed via source and target branches