185 Commits

Author SHA1 Message Date
Adit Sarfaty
db005d3221 TVD IPAM support
Adding an IPAM driver for the TVD plugin which will redirect the
requests to the V/T driver.

Change-Id: Iea48c7de053b0e7545fdae2a8e38c7b489d61409
2018-02-21 12:38:56 +02:00
Adit Sarfaty
c6c155c1aa TVD: Add service plugins to separate list results
Adding service plugins for QoS, VPNaaS and L2Gateway
and updating the BGP plugin
to prevent users from getting objects belonging to a different
plugin

Change-Id: I3545c3acefaf50ca6937a0b7a65c131c569317cd
2018-02-20 10:34:18 +02:00
Nguyen Hung Phuong
68a9b50cf8 Remove pbr warnerrors in favor of sphinx check
This change removes the now unused "warnerrors" setting, which is
replaced by "warning-is-error" in sphinx releases >= 1.5 [1].

[1] http://lists.openstack.org/pipermail/openstack-dev/ 2017-March/113085.html

Change-Id: Ie82fce03c73f4a78b557caecc5bcf4ad9c8b7cb1
Closes-Bug:#1693670
2018-02-01 13:48:04 +07:00
Adit Sarfaty
4530377c60 TVD: FWaaS plugins
Adding FWaaS v1/v2 plugins to be used with the TVD core plugin.
The plugins will make sure to separate the v/t returned lists
using the same solution that was introduced for the LBass, now as a
general class decorator.

Change-Id: I5f01b8cf093d5ef3b340dce2d12fc41031dd12e9
2018-01-23 10:18:21 +02:00
Gary Kotton
69d87b94ce TVD: support lbaasv2 'provider' filtering
The patch ensures that only a V tenant can see v resources and the
same for a T tenant/project.

NOTES:
1. In the neutron configuration file a new service plugin is created.
   So we need the following:
[DEFAULT]
service_plugins = vmware_nsxtvd_lbaasv2

2. The extensions path needs to be updated so that the default LBaaS
   extensions can be loaded.

So for example in the devstack case we need to configure:
[DEFAULT]
api_extensions_path = /opt/stack/neutron-lbaas/neutron_lbaas/extensions

Change-Id: Iea497cbb150048bedf712a195c7854e4836ad4a5
2018-01-14 22:02:15 -08:00
Kobi Samoray
84da10cf22 NSXv HK: recover broken backup edge appliances
When there is a failure during the recycling of an edge appliace to the
backup pool, the edge at the backend may still be attached to networks
and use IP addresses which are free for reuse by Neutron.
Housekeeping job should address such cases.

Change-Id: I3a8ba622f742064bdc8906ba745da0a54a4576ac
2017-12-28 14:42:02 +00:00
Adit Sarfaty
5517d697c1 TVD: Update devstack doc with different services
Change-Id: Iaf6fb4227df7c919d6bd757a8b47d1c96b289758
2017-12-24 13:12:22 +00:00
Zuul
30885efb36 Merge "Plugin housekeeper" 2017-12-21 16:41:30 +00:00
Kobi Samoray
33c1830734 Plugin housekeeper
Implements a generic mechanism to cleanup and fix various breakages and
issues between neutron, plugin and backend.
Also adds a housekeeping job which detects and handles broken DHCP edge
issues.

Change-Id: I5324befbe2c7740b8ed47e0a20586f8aca0726f1
2017-12-20 16:02:47 +02:00
Adit Sarfaty
189d8d6955 NSX-TV fwaas drivers
Drivers for FWaaS V1/V2 for the NSX-TV plugin
Those drivers are just wrappers calling the right driver according to
the project of the firewall object.

Change-Id: Ia073da9c91cb4d69d772b3e0d0ab6f5c3fd60795
2017-12-19 08:49:32 +02:00
Gary Kotton
792a6a0103 NSX TVD: V, T and simple DVS Coexist in the same plugin
Introduce a plugin that can work with all of the VC and NSX
offerings under the same umbrella of a single plugin.

Co-Authored-By: Adit Sarfaty <asarfaty@vmware.com>

Change-Id: I0449d64e3cf79b7a3a846dacba95e8854d53bdf8
2017-12-17 01:31:43 -08:00
Pierre Hanselmann
1d9d363bba DVS: Add support for dns-integration extension
One can enable DNS integration for the upstream neutron
DNS integration extension by setting:
nsx_extension_drivers = vmware_dvs_dns

Closes-Bug: #1727626
Change-Id: If776d21679acfa2abf8018a8f6f19b58be24cb4b
2017-10-30 15:45:17 +00:00
Adit Sarfaty
afdb9ea7ac NSX|V3 refactor fwaas to support plugin rules
For DHCP relay support, and possibly other features, there is a need to
add specific allow rules to the router firewall between the FWaas v1/v2
rules, and the default drop rule.
This patch set the structure to do that, without actually adding new rules.
In case of FWaaS v2 the additional rules are per router interface.

Change-Id: I63d754495f56ec9081d84dcea6fb688ee1c41dbd
2017-10-04 18:19:17 +00:00
Jenkins
1328bc1fd7 Merge "Remove wrong alias from setup" 2017-09-19 12:38:39 +00:00
Adit Sarfaty
32e95f47b5 NSX|v3: FWaaS v2 support
FWaaS V2 support in NSX-v3.
Support different firewall group per router interface port for
igress/egress.
limitation: cannot support egress rules with source ip, or ingress
rules with destination ips.

Depends-on: I2a37be5518bfc8124ffca2ab05f684d8c1c3d673
Change-Id: I3ed70fa48d078bed15f30e855b73bdfb11d11c6e
2017-09-18 07:42:30 +00:00
Tong Liu
00be925de3 Remove wrong alias from setup
In vmware_nsx/plugin.py, NSX|mh plugin has been defined as
NsxPlugin and there is no NsxMhPlugin. To use alias for NSX|mh
plugin, vmware_nsx should be used instead of vmware.

Change-Id: Iff5cfe5a60809cf3c26d4445f0c3fb4b89db968f
2017-09-14 09:46:37 +00:00
Gary Kotton
508c6262a2 Remove vmware_nsx_tempest
This now existsin the vmware_nsx_tempest_plugin

Change-Id: I76e5856deeeb06b87675314635d06aa0291143eb
Depends-On: I804c3fd1e0c9cbeb454677e7951072ad74391fec
2017-08-15 17:02:55 +00:00
Adit Sarfaty
754e0e7561 NSX|V3: FWaaS-v1 support
Adding FW rules to protect the traffic north-south behind a T1 router.
This will be done only if a firewall was attached to the router.
This includes:
- FWaaS rules
- Drop all default rule

When the firewall is deleted or the router removed from it,
a default allow all rule will be set.

For the rotuer firewall to work, the rotuer NAT rules should set
nat-bypass=False.

Change-Id: Iba03db8ca67ee10d1c54b96fb41a888cb549684d
2017-06-17 05:18:15 +00:00
Chandan Kumar
eb293bd418 Fixes vmware_nsx_tempest tempest plugin issues with tempest
* Added vmware_nsx_tempest under packages in setup.cfg so that
  tempest can discovers it.
* Removed pbr version from vmware_nsx_tempest (in-tree tempest plugin)
  as it causes versioning issue with the main package vmware_nsx.
* Added all sections and options defined in tempest plugin conf
  so that tempest can retrive all the tempest sample configurations.

Depends-on: Iab0202a28bfa525c4cd91e776ac2bdba56a807f6

Change-Id: I2f706b8cdb31c53d951b059f939fb0d6afc32958
Closes-Bug: #1691122
2017-05-17 10:24:53 +00:00
shaofeng_cheng
1f59123100 Add firewall_drivers entry_point in setup
Add firewall_drivers entry_point for vmware_edge.

Change-Id: I25aa8fb2620ccbf6cdc19a711022c82bea70919d
2017-05-15 15:45:44 +08:00
Jenkins
add5a5bfc8 Merge "Rename api-replay to nsx-migration" 2017-05-11 23:37:30 +00:00
shaofeng_cheng
baef191d1f Add vmware_nsxv entry_point in setup
If config neutron.core_plugins values for vmware_nsx.plugin.NsxVPlugin.
It throw warning for 'stevedore.named [-] Could not load vmware_nsx.plugin.NsxVPlugin'.
So,Add vmware_nsx vmware_nsxv vmware_nsxv3 and vmware_dvs entry_point in neutron.conre_plugins group.

Change-Id: Ie2a5a4d00bd15ad838737948e2eb8eec69f3303b
2017-05-11 14:34:55 +08:00
Adit Sarfaty
6cc71fc758 Rename api-replay to nsx-migration
Change-Id: I2a8889119b52123427a4ae269cc1fb669375c36e
2017-05-10 18:14:56 +03:00
Eric Brown
0294eaed7d Use https for *.openstack.org references
The openstack.org pages now support https and our references to
the site should by default be one signed by the organization.

Change-Id: I0448c7bc0294db867bc1766da7aaf07912575dbe
2017-02-06 15:45:18 -08:00
Shih-Hao Li
64dec92beb NSXV+NSXV3: Add support for dns-integration extension
One can enable DNS integration for the upstream neutron
DNS integration extension by setting:
nsx_extension_drivers = vmware_nsxv_dns (for NSXV)
nsx_extension_drivers = vmware_nsxv3_dns (for NSXV3)

Change-Id: Id100f8034e602d92310d22f900c48d9dfbe59a8d
2017-01-15 09:06:09 -08:00
Adit Sarfaty
1266099049 NSX|V3 IPAM support
The NSX-V3 plugin will use the NSX-V3 backend IPAM.
An IP pool will be created for each subnet, and port IPs will be allocated
from this pool.
The current backend limitation is that we cannot allocate a specific IP,
so port create/update with fixed_ips will fail, unless the requested ip
is the subnet gateway ip.

To enable this option set 'ipam_driver = vmware_nsxv3_ipam' in the
neutron.conf

Change-Id: I5263555cbb776018a5d01f19d0997fd2adf6483d
2017-01-15 12:49:00 +00:00
Adit Sarfaty
8d7f6e07d0 Fix IPAM drivers entry point in setup.cfg
Change-Id: If45878f800bb669595d77bbb56823f7c2f026036
2017-01-10 09:56:21 +02:00
Eric Brown
53b8498fc6 Remove references to Python 3.4
Now that there exists only a gate job for Python 3.5 and not 3.4,
we should remove those references to the 3.4 that is untested.

Change-Id: Idb66d124611de879b33c0f8bd20f37f24da443b4
2017-01-05 15:42:39 -08:00
Adit Sarfaty
b8f5312bb4 NSX|v add IPAM driver to setup.cfg
This will allow simpler configuration of the ipam_driver in the neutron.cong

Change-Id: Icc81117ab778528b901a9eeaad152a507acad0c2
2016-12-08 13:32:55 +00:00
Adit Sarfaty
e30d060cb2 Add security group extensions to OSC
Change-Id: Ic626c3efed3dfd90ae5045591f6949b2b81915b1
2016-11-10 15:50:22 +02:00
Adit Sarfaty
62e5881010 OCS plugin + initial extensions support
Create an openstack client plugin for vmware nsx, and add the some of
the extensions suport: router-type, router-size, subnet dhcp-mtu and
dns-search-domain and port provider security groups and vnic index

Work for future patches:
- More unit tests (provider-security-groups)
- Add the rest of the extensions

Change-Id: I5b335de000b310cbcbb9a2f81483fd28f8d9afea
2016-10-30 12:33:03 +02:00
Adit Sarfaty
ce9003f498 NSX-V Service insertion support
The service insertion feature allows us to redirect some of the NSX traffic to an external
security vendor like Palo-Alto or checkpoint for advanced inspection.

The implementation contains:
Enable the flow classifier plugin, and use it to create redirect rules on NSX
When the flow classifier plugin is initialized a new security group is created
and added to the configured service profile

When a vm port with port security is created/updated, it is added to this security group
When the admin user create a flow classifier entry, a backed redirect rule will be created.

DocImpact: new NSXV Configuration parameters:
service_insertion_profile_id = <service profile id, i.e. serviceprofile-1>

DocImpact: The flow classifier methods should be added to the policy.json as admin only

Change-Id: I67a132d4b35764c6940516a8365a2749d574aad2
2016-07-13 11:29:05 +03:00
Eric Brown
b152dda04b Add Python 3.5 venv and classifier
Now that there is a passing gate job, we can claim support for
Python 3.5 in the classifier. This patch also adds the convenience
py35 venv.

Change-Id: I14f4f90ca0f0c863f9175934f63c95b9115f9b8c
2016-07-09 22:31:01 -07:00
Boden R
2228c7afd5 Prep for pbr warnerrors
As per [1] the next version of pbr will properly support pbr/Sphinx
warnerrors during doc builds. We should enable warnerrors upon
the next pbr release and verify our doc build completes successfully.

[1] http://lists.openstack.org/pipermail/openstack-dev/2016-June/097849.html

Change-Id: I20cbbefb9dce05770dafa37a6ee1a59afc29c218
2016-06-24 08:12:39 -06:00
Kobi Samoray
30f372d1af Revert "Temporarily disable tempest plugin"
This reverts commit 9902635dc0387e745a7c36d5b6f9e8ba95eecb25.

Change-Id: I6a8caf96f00cf65898d140cc38b13a1356506afc
2016-06-21 08:28:41 +00:00
Kobi Samoray
9902635dc0 Temporarily disable tempest plugin
Tempest plugin breaks the CI due to changes to upstream tempest project.
This patch disables the tempest plugin to allow the CI to work.
Plugin should be re-enabled once issues are resolved.

Change-Id: I52bc8309d6b75f91ec66b3c11d10d1527da0177e
2016-06-19 08:12:31 +00:00
Aaron Rosen
a8443957cb Add neutron-api-reply cli tool
This tool reads from one neutron server and then replays all the
of the api calls required to create the resources on another server.
It requires the dest-neutron service to be in api-replay-mode to allow
us to specify the ids of resources.

This patch migrates all resources expect for floatingips and uplinking
the router.

This patch also makes some modifications to the plugin code to make migating
security groups especially the default security group and rules that
users have added possible.

Change-Id: Id79c880317bfbb45c4edad7cdb1e95a6c8dc21e6
2016-06-01 09:40:02 -07:00
Abhishek Raut
f70a8c4b8c [L2-gateway]: Fix l2gw plugin due to networking-l2gw changes
Change: Ib56ee8bfd182c031e468c503acb0cd75daea8c40 broke vmware-nsx
L2 gateway plugin for master and mitaka release. Due to this the
l2 gateway plugin for vmware-nsx would not load.

This patch makes the required changes in vmware-nsx to load l2gw
plugin.
This patch also adds a README file to include steps to bring up
L2 gateway plugin with devstack.

Closes-Bug: #1573327
Change-Id: I433c7f51df80ff6ea4250e38c981ffb363cf1b17
2016-04-09 02:44:36 -07:00
Adit Sarfaty
6fbf7ff64c NSX|V3 add qos support for ports
Add support for the qos service in NSX|V3, including:
- Attach/Detach qos policy to a new or updated port
- Allow qos configuration on ports with internal networks only
- Update the switch profile with the BW limitations and tags
  through the qos notification driver
- Add a new mapping db table to link the policy id and the
  nsx-v3 switch profile id

For this to work, the following configuration should appear under the 'qos' section in the neutron.conf:
notification_drivers = vmware_nsxv3_message_queue

Change-Id: I4016de756cebe0032e61d3c2a5250527e44b49e4
2016-04-20 09:11:41 +03:00
Abhishek Raut
5f1a62a0f1 Remove vmware-nsx's static example configuration file
This patch is a follow up to the auto generate config file patch[1]
which removes the static example nsx.ini file from the repo as
it is now redundant.

[1]: https://review.openstack.org/#/c/303673/

Depends-On: Iff4ea37b52616295b262ead53947acb5b0cd9cd7

Change-Id: I61ee6fe873cfeac9dfe6d9eb7b0f90dd7c251d51
Partial-bug: #1568215
2016-04-07 04:36:14 -07:00
Abhishek Raut
6c1d841ff3 Automatically generate vmware-nsx configuration files
This patch adds support to automatically generate config files
for vmware-nsx repo using oslo config generator[1] for all
VMware plugins.
Tox can be used to generate a sample config file using the
following command:
    tox -e genconfig
This will generate a config file "nsx.ini.sample" under
vmware-nsx/etc/ folder.

This patch also modifies devstack scripts to use the
auto-generated config files and adds more information to help
texts in config modules.

[1] http://docs.openstack.org/developer/oslo.config/generator.html

Change-Id: Iff4ea37b52616295b262ead53947acb5b0cd9cd7
Partial-Bug: #1568215
2016-04-13 07:24:06 +00:00
Adit Sarfaty
24a84004ff NSX|V add qos support for networks
Add support for the qos service in NSX|V, including:
- Attach/Detach qos policy to a new or updated network
- Allow qos configuration on a backend network only,
  and only if use_dvs_features is True
- Update the bw limitations on the edge through the dvs
- Update the networks bw limitations when a policy or rule changes
  through the QoS notification driver

Change-Id: Icee25b59e8e0f3c1c093077b631250a908e127c1
2016-04-06 14:51:57 +03:00
Akihiro Motoki
b27265cc2c Update translation setup
Follow new infra setup for translations, see spec
http://specs.openstack.org/openstack-infra/infra-specs/specs/translation_setup.html
for full details.

This basically renames
vmware-nsx/locale/vmware-nsx.pot to
vmware_nsx/locale/vmware_nsx.pot. For this we need to update
setup.cfg.

Update also domain name in _i18n.py.

Let's remove the po and pot files in the outdated paths.
The updated scripts work without them. So, we can just
delete the files and once the infra script runs,
an updated pot file together with translations
will be imported automatically.

Change-Id: Id4bade9ffd23c57153b415514c82b384fd0977aa
2016-01-29 07:15:35 +09:00
Alex Kang
00c98dce02 init release of vmware-nsx tempest tests in tempest external plugin
installation procedure & tech-notes at vmware_nsx_tempest/README.rst
With this plugin method, vmware_nsx_tempest tests can be treated as
tempest tests and executed under tempest environment.

Fix nsxv_client to support multiple transport zones.

Change-Id: Id103c0ce03d75749fe6295108db48493f565b05a
Implements:  blueprint vmware-nsx-tempest-plugin
2016-01-21 10:02:00 -08:00
Boden R
70fa532032 Move python_nsxadmin out of a top-level namespace
It is not a good idea to have a top-level "tools" namespace, this
name is too generic and already taken in PyPi (see
https://pypi.python.org/pypi/tools).

This patch moves python_nsxadmin to the vmware_nsx.tools namespace,
adjusting all imports and making sure setup.cfg is adapted
accordingly.

Change-Id: I75922db2010194fe59db424cc4615c7ba57c1b81
2015-12-17 15:34:45 -07:00
Akash Gangil
874b1127a9 Install the tools folder on vmware_nsx install
Previously we have tools/python_nsxadmin folder get added
to /usr/local/lib/python2.7/dist-packages, however this didn't
capture the __init__.py file in tools folder. The __init__.py
is needed for any pakcage to be imported without that

import tools.python_nsxadmin would fail, since python won't recognize
tools as a module.

Original intention to have tools/python_nsxadmin was towards having
python_nsxadmin in the dist-packages instead of tools. But haven't yet
figured out how to do that in setuptools (setup.cfg)

Change-Id: I3641235e462866ccb85b7ada625f8ccaa282e1ba
2015-12-04 08:02:46 -08:00
Akash Gangil
72d72623a9 Admin util should work from any dir
It wasn't working because of two reasons:
1. The packages filed in setup.cfg takes a directory name.
so specifying tools.python_nsxadmin.admin didn't put the py files
in /usr/local/lib/python2.7/dist-packages when we pip installed
vmware-nsx package. (sudo pip install .). So changing it to tools
installs all the code in tools including python_nsxadmin there. Read
2 to know why we need this.

2. To enable admin utility to dynamically pick up any hooks that users
might add we use the importlib module. The bug was here, as the path was
absolute tools/python_nsxadmin/.... So when we executed it from other
diretory those modules were not imported. So I changed that to relative
path. Though, over here there could be a case where the hooks location
directory path contains a '-' / dash, which will cause it to fail.

>>> import
>>> home.gangil.t1-review.e_nsx.tools.python_nsxadmin.admin.plugins.nsxv.resources.edges

  File "<stdin>", line 1

    import
home.gangil.t1-review.vmware_nsx.tools.python_nsxadmin.admin.plugins.nsxv.resources.edges

                         ^

SyntaxError: invalid syntax

So we install the tools code using setup.cfg and then just import
resources from there.

Now it works from any directory.

Change-Id: Idc414fabc769d0503974e8f77b84d32008b3c08a
2015-12-02 07:10:00 -08:00
Gary Kotton
6b91e5f42f Fix translation file names
It should have been in the directory vmware-nsx and not
vmware_nsx.

Change-Id: I40fd8dc1de15da367bacde0be019a4a04385b448
2015-11-29 23:55:15 -08:00
Gary Kotton
0e9bb23849 Setup for translation
To start translation, we need to initially import the
translation file - and place it at the proper place so that
the usual CI scripts can handle it.

The proper place is for all python projects
$PROJECT/locale/$PROJECT.pot - see setup.cfg.

Further imports will be done by the OpenStack Proposal bot.

Setup also setup.cfg with the usual babel commands and add the default
babel.cfg file.

Change-Id: I2c0350e15c68bcae2a0611dade5f5a0705a9387d
2015-11-29 03:13:04 -08:00
Shih-Hao Li
09d19bb138 Divide vmware_nsx/plugins into plugin-specific subdirectories
This patch will create:
vmware_nsx/plugins/dvs for DVS specific files
vmware_nsx/plugins/nsx_mh for MH specific files
vmware_nsx/plugins/nsx_v for nsx_v specific files
vmware_nsx/plugins/nsx_v3 for nsx_v3 specific files

also move vmware_nsx/vsphere/ to vmware_nsx/plugins/nsx_v/vsphere/.

This is part of new vmware_nsx directory structure proposed in
https://goo.gl/GdWXyH.

Change-Id: I00ee12da2eea0add988bae3d4f3e12940ea829bb
2015-09-16 16:14:47 -07:00