3899 Commits

Author SHA1 Message Date
Dean Troyer
dd7da49325 Nova net functional tests round 2
* floating ip
* ip availability
* network qos policy
* network qos rule
* network qos rule type
* network rbac

Change-Id: Id3946bdff43bfef3a1d879c058bde4792bd299c6
2017-04-28 09:46:51 -05:00
Dean Troyer
e0d1af94a1 Nova net functional tests round 1
* address scope
* network agent
* network flavor
* network flavor profile
* network meter
* network meter rule

Also create a new common network functional test class
NetworkTests to house the setting of haz_network in a single place.
The individual test skipping stays in the final classes to re-enforce
the idea that some tests work with both Nova-net and Neutron.

Change-Id: Ie3910231c6fc9e2031438c599afa904f43c874a7
2017-04-28 06:39:21 -05:00
Jenkins
7b609ebd55 Merge "Fix server create with nova-net" 2017-04-27 03:06:50 +00:00
Jenkins
19a7081aa0 Merge "Fix quota functional tests for nova-net" 2017-04-27 03:03:08 +00:00
Dean Troyer
871450abcd Fix quota functional tests for nova-net
We need to skip some functional tests when testing against a nova-net cloud
so add the bits to detect that.

Also JSON-ify the quota functional tests and add the skips for nova-net.

Change-Id: Ibfeeb3f967f34c98e80271a8214cf95dc50407f1
2017-04-26 23:52:34 +00:00
Dean Troyer
bffc98e4e5 Fix server create with nova-net
A Neutron-ism slipped by in server create.

Change-Id: Id590d7f93df2a41d7bd7617459a2af159a6f8071
2017-04-26 18:49:50 -05:00
Jenkins
7939fea6e7 Merge "Updated from global requirements" 2017-04-26 23:40:25 +00:00
Jenkins
b6087cd284 Merge "Functional test for subnet_pool" 2017-04-26 23:23:01 +00:00
OpenStack Proposal Bot
b38261e84b Updated from global requirements
Change-Id: Ib3ea4225636bfa815f7cf60481d2adc07077123c
2017-04-26 19:38:28 +00:00
Jenkins
0a0bcbbda2 Merge "Remove ipdb installation in tox debug section" 2017-04-26 19:29:43 +00:00
Jenkins
a28364a37a Merge "Fix NoneType error for volume snapshot create command" 2017-04-26 19:08:11 +00:00
Jenkins
95736cebc3 Merge "SDK refactor: Set "is_admin_state_up" for network agent" 2017-04-26 18:50:35 +00:00
jiahui.qiang
d519911c43 Functional test for subnet_pool
Refactor functional tests for testing more command options.

Change-Id: I0c9c3b04dd2b79766a8fe82cbc5315c030f4784d
2017-04-26 12:51:58 -05:00
Huanxuan Ao
1c49a1f01d Fix NoneType error for volume snapshot create command
In volume snapshot command, <volume> is the same
as <snapshot-name> when --volume is not specified,
but <volume> cannot be None, so when <snapshot-name>
is not specified (<snapshot-name> is None), a NoneType
error appears.
So make <snapshot-name> no longer optional, it should
be always present.

Change-Id: I3d9f10753a8ef601e70816421c160598e2cc811f
Closes-bug: #1659894
2017-04-26 11:07:08 -05:00
Jenkins
bf1f47c1be Merge "Make test_server.py more elegant and simple" 2017-04-25 15:24:07 +00:00
Jenkins
7977f7df18 Merge "Add --network and --port to server create" 2017-04-25 13:54:46 +00:00
Dean Troyer
ef99f44462 Improve no-auth path
The commands that do not require authentication sometimes still need
to call ClientManager.is_network_endpoint_enabled() to see if Neutron
is available.  Optimize the paths a bit to skip auth when it is not
necessary; the upshot is Neutron will be assumed in these cases now.

This gets a LOT cleaner when it appears is a future osc-lib.

Change-Id: Ifaddc57dfa192bde04d0482e2cdcce111313a22a
2017-04-24 18:57:10 -05:00
Rui Chen
af435ee0a8 Remove ipdb installation in tox debug section
The lastest ipdb depends on ipython 6.0, but ipython 6.0
only can be installed in python 3.3 and above, see
http://paste.openstack.org/show/607632/ . If we try to
run "tox -e debug" in python2.7, the install error is raised
and block the function. Remove the ipdb installation, it's
not necessary, we can use pdb to replace.

Change-Id: Ib47bb5925b7a5b1d3a319b58fa219c1b57dccb93
2017-04-24 15:06:26 +08:00
David Rabel
6dc17bb1fb Make test_server.py more elegant and simple
Use only one line for mocking network resources like ports
and networks in test_server.py.

Change-Id: I451a504c3afdd365e64d66079516ec6308c206db
Depends-On: I624b1bc557a195bdf8a7c5a32dc0e72a6fa8b075
2017-04-21 13:06:20 +02:00
Huanxuan Ao
db6081fb80 Fix network list functional test
An error in network func test broke our CI,
looks like the "is_default" should be "False"
by default for now.

Change-Id: I021eb8abd9bdf55c7c06031152c107312f104b34
2017-04-19 21:47:57 +08:00
Dean Troyer
107cad200a Low-level Compute v2 API: floating ip pool
api.compute.APIv2 floating ip pool function.

novaclient 8.0 is now released without support for the previously
deprecated nova-net functions, so include a new low-level REST
implementation of the removed APIs.

Also includes a handful of cleanups that the previous security group and
floating IP reviews missed.

Change-Id: I20116ec4fc1113857d8d917bfb30fa3170d05b9f
2017-04-18 08:57:34 -05:00
Jenkins
7e1350815e Merge "Clean up password prompt work-arounds" 2017-04-18 13:35:53 +00:00
Dean Troyer
b2783dc3c4 Low-level Compute v2 API: network
api.compute.APIv2 network functions.

novaclient 8.0 is now released without support for the previously
deprecated nova-net functions, so include a new low-level REST
implementation of the removed APIs.

Change-Id: If230f128e91cda44461fe93c976cac2aecec2252
2017-04-17 19:45:21 -05:00
Dean Troyer
6f473be588 Split network tests
Split up the network unit tests between compute and network APIs
into separate files in preparation for reworking the compute (nova-net)
implementations to deal with the removal of deprecated nova-net
support in novaclient 8.0.0.

No code changes are intended here, just splitting two files into four.

Change-Id: I2d001118af436f95025d2851341f8ca802e78830
2017-04-17 17:11:43 -05:00
Jenkins
b0ce95745d Merge "Low-level Compute v2 API: floating ip" 2017-04-17 21:14:05 +00:00
Jenkins
18206a9224 Merge "Low-level Compute v2 API: security group rules" 2017-04-17 19:40:34 +00:00
Jenkins
578950335f Merge "Update to tox.ini" 2017-04-17 17:44:26 +00:00
Jenkins
9a1c9cabd4 Merge "Low-level Compute v2 API: security group" 2017-04-17 17:35:33 +00:00
Jenkins
62d71aa243 Merge "Allow override of distributed router flag" 2017-04-17 15:18:20 +00:00
OpenStack Proposal Bot
b168f2d998 Updated from global requirements
Change-Id: Icd26cb6d2525ff1736923c39e9c64eb12f6d39b6
2017-04-12 04:21:53 +00:00
Dean Troyer
e6ea45b283 Low-level Compute v2 API: floating ip
api.compute.APIv2 floating ip functions.

novaclient 8.0 is now released without support for the previously
deprecated nova-net functions, so include a new low-level REST
implementation of the removed APIs.

Change-Id: Ic461b8d15e072e0534dcd73fff6857581d83c89b
2017-04-11 02:10:26 -05:00
Dean Troyer
1bf6706ad1 Low-level Compute v2 API: security group rules
api.compute.APIv2 security group rule functions.

novaclient 8.0 is now released without support for the previously
deprecated nova-net functions, so include a new low-level REST
implementation of the removed APIs.

Change-Id: Ieabd61113bc6d3562738686f52bb06aa84fca765
2017-04-11 02:08:57 -05:00
Dean Troyer
4289ddd47a Low-level Compute v2 API: security group
api.compute.APIv2 starts with security group functions.

novaclient 8.0 is now released without support for the previously
deprecated nova-net functions, so include a new low-level REST
implementation of the removed APIs.

Change-Id: Id007535f0598226a8202716232313e37fe6247f9
2017-04-11 02:08:04 -05:00
Rui Chen
a071ff91c3 Add document about renaming OS_ENDPOINT_TYPE to OS_INTERFACE
The patch https://review.openstack.org/#/c/198506/ rename option
--os-endpoint-type to --os-interface a year ago, but lots of users
switch to osc from these project specified clients, like: novaclient
and neutronclient, they used OS_ENDPOINT_TYPE and --os-endpoint-type
for long time, we should add the notes into openstackclient manpage,
let them know the gap exists, and how to make it works.

Change-Id: Ic84a60744aa4e519994a18104deae0c2b5b8b0ed
Closes-Bug: #1678144
2017-04-11 15:01:49 +08:00
Dean Troyer
09286ad858 Split floating IP tests
Split up the floating IP unit tests between compute and network APIs
into separate files in preparation for reworking the compute (nova-net)
implementations to deal with the removal of deprecated nova-net
support in novaclient 8.0.0.

No code changes are intended here, just splitting two files into four.

Change-Id: Id62148bb21e913116f9f2084c5761cfa24e8d34c
2017-04-10 18:07:00 -05:00
yangweiwei
13bba78ca5 Update to tox.ini
When do the action "tox -e pep8", result is "ValueError: No closing
quotation". Which is caused by the tox.ini. The min tox version is
1.6. In my environment, tox version is 2.2.1. If the tox version is
more than 2.3, the error will not happen.

Depends-on:  Iee7b043ac7d381dadf89d26098f69e935ed81d6b
Change-Id: Id10ddf6244e7e25e6f66c97773d426b0b4789479
2017-04-07 18:33:39 +00:00
David Rabel
8549071363 Add --network and --port to server create
--nic option is quite unhandy. It is better to have
two seperate options --network and --port to add a
network to a new server.

Change-Id: I523abdc83ca2dd4c5dd3871f8f109c2bf57c2e02
Closes-Bug: #1612898
2017-04-07 16:36:18 +02:00
OpenStack Proposal Bot
358175158d Updated from global requirements
Change-Id: I8e7362555d330613a87c095b89bb2783df03a6e3
2017-04-07 14:32:41 +00:00
Jenkins
54723427b6 Merge "Split security group tests" 2017-04-07 14:11:19 +00:00
Dean Troyer
488ca596ec Split security group tests
Split up the security group tests between compute and network APIs
into separate files in preparation for reworking the compute (nova-net)
implementations to deal with the upcoming removal of deprecated nova-net
support in novaclient 8.0.0.

No code changes are intended here, just splitting two files into four.

Change-Id: I3fbdde45f593a30de545ddd11e319a4d6f900b18
2017-04-06 12:23:25 -05:00
venkata anil
fe59e339ae Allow override of distributed router flag
When router_distributed=True is set in neutron.conf,
user can't override this and create a centralized router
through openstack client. Openstack client allows modifying
routers from distributed to centralized after creation but
not supporting centralized flag during creation. We allow
centralized and distributed flags during router creation
with this change.

Closes-bug: #1664255
Change-Id: I75f72ca695338ad8c381cfa89fbb9d8e61ee7bc5
2017-04-06 14:37:14 +00:00
Jenkins
80726b1340 Merge ""floating ip set/unset port" for OSC" 2017-04-06 01:55:24 +00:00
Jenkins
8983373e52 Merge "Add "qos-policy" option to "port create" & "port set"" 2017-04-06 01:43:44 +00:00
Dean Troyer
46b8cad4c3 Clean up password prompt work-arounds
osc-lib 1.2 is minimum and now handles the password prompting.

Change-Id: Ie11ad64796d3a89c7396b321c34947d622d1ed39
2017-04-05 13:54:08 -05:00
Jenkins
27f96a3a7a Merge "Enable to create legacy router" 2017-04-05 17:00:49 +00:00
Sindhu Devale
763c8c5670 "floating ip set/unset port" for OSC
Implements Neutron feature of floating ip associate/disassociate
into OpenStack Client.

Previously, network.find_ip() function only supported to
search floating ip by UUID. Hence, _find_floating_ip()
function is used in floating_ip.py, to search fip both by UUID
and ip_address. [1] adds the ability to find fip object using both UUID
and ip_address. This functionality however, won't be available until
the SDK is released. Hence, we continue to use _find_floating_ip()
method, which was cleaned up by [2] to remove the use of ip_cache.
Once, the SDK is released, we will remove all the usage of
_find_floating_ip() method and instead only use network.find_ip().

[1] https://review.openstack.org/#/c/449879/2
[2] https://review.openstack.org/#/c/447938/

Change-Id: I6c5222287c46ca42365917d2deae70bdb626347
Co-Authored-By: Reedip<reedip.banerjee@nectechnologies.in>
Co-Authored-By: RuiChen<chenrui.momo@gmail.com>
Closes-Bug: #1560297
2017-04-05 16:12:40 +00:00
Ha Van Tu
5ff2cfd042 Add "qos-policy" option to "port create" & "port set"
This patch adds "qos-policy" option to "port create" command,
and "qos-policy", "no-qos-policy" options to "port set" command
and "qos-policy" option to "port unset".

Change-Id: I78072e1ff0dd30a2e23a0fb833ce6ab5cf246016
Co-Authored-By: Nguyen Phuong An <AnNP@vn.fujitsu.com>
Co-Authored-By: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Partial-Bug: #1612136
Partially-Implements: blueprint network-commands-options
2017-04-05 15:56:52 +00:00
Jenkins
65b61d3a9c Merge "Enable to specify which fixed-ip to add to a vm." 2017-04-05 02:55:11 +00:00
Jenkins
25a77f7c7c Merge "Structure FindFloatingIP() to work without ip_cache" 2017-04-04 20:31:15 +00:00
Reedip
0e42ea3ae3 Structure FindFloatingIP() to work without ip_cache
Currently we have an ip_cache returned from _find_floating_ip() which
is generally ignored as it is not always required.

This patch removes the need of ip_cache in _find_floating_ip().

Co-Authored-By: Sindhu Devale<sindhu.devale@intel.com>

Change-Id: I8b92271185f82f275fa73adad03e9dad70be70e4
2017-04-04 16:27:24 +00:00