3227 Commits

Author SHA1 Message Date
Matt Riedemann
874b03068f Make Server.networks use a predictable sort order
This changes the Server.networks property method to return
an OrderedDict where the keys (network labels) are sorted
which will allow for a predictable sort order on the resulting
networks attached to a Server resource.

This affects the output of "nova list" and "nova show" commands
so a simple release note is added to mention the change.

Change-Id: I2e9b3c6a256509c045966035da24d58628f1b33b
2019-02-20 11:58:35 -05:00
Corey Bryant
81ea9887f0 add python 3.7 unit test job
This is a mechanically generated patch to add a unit test job running
under Python 3.7.

See ML discussion here [1] for context.

[1] http://lists.openstack.org/pipermail/openstack-dev/2018-October/135626.html

Change-Id: I3c9416b6628d0217b1bd46b51d976806645287fe
Story: #2004073
Task: #27433
2019-02-15 03:00:50 -05:00
Stephen Finucane
162f4769b8 Microversion 2.68: Remove 'forced' live migrations, evacuations
Update the commands and Python API bindings to reflect the new
microversion. The various evacuate microversion functions are DRY'd up
along the way.

Change-Id: Ibfc905292258ffde05800387e5d6bbad4823085c
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
Depends-On: https://review.openstack.org/#/c/634600/
Implements: blueprint remove-force-flag-from-live-migrate-and-evacuate
2019-02-13 21:15:23 +00:00
Takashi NATSUME
8eb7d1c5cc Remove deprecated novaclient.v2.contrib modules
All modules of novaclient.v2.contrib have been removed.
The 'only_contrib' parameter for the
'novaclient.client.discover_extensions' method is no longer valid.

Change-Id: I6da83057dda1f27afe98a2412bc0815f100f34a4
2019-02-07 15:00:36 +09:00
ZhijunWei
85e9b58e9b Update hacking version
1. update hacking version to latest
2. fix the pep8 failed

Change-Id: I484a40fe3cb868d223a807edcd3e20f5e0ebdf4e
2019-01-04 14:46:07 +08:00
zhaolihui
b13ba0138f Fix flavor keyerror when nova boot vm
When creating a server (the 'nova boot' command),
it calls 'POST /servers' API.

The response does not have 'addresses' and 'flavor' attributes.
When accessing 'networks' attribute in the '_print_server' function,
it calls 'GET /servers/{server_id}' and get the 'addresses' and
'flavor' attributes.

If 'GET /servers/{server_id}' fails, the server object does not have
the 'flavor' attribute, then KeyError is raised when accessing it.

Fix the issue by making it raise a CommandError
when the 'GET /servers/{server_id}' fails.

Co-Authored-By: Takashi Natsume <natsume.takashi@lab.ntt.co.jp>
Change-Id: I3ef096c61b0e05a637ab0c4a1027338fa87e4f09
Closes-Bug: #1781368
2018-12-13 07:50:37 +00:00
sunjia
a789bd30ae Change openstack-dev to openstack-discuss
Mailinglists have been updated. Openstack-discuss replaces openstack-dev.

Change-Id: I157626d7aa539e583d20f2f8aa39e06188347573
2018-12-03 21:41:17 -05:00
qingszhao
3f967d9758 Add Python 3.6 classifier to setup.cfg
Change-Id: I091c82f60d9ae984cf61be8c6fe95ec68817cb75
2018-11-30 07:11:18 +00:00
Takashi NATSUME
1df18e2d99 Fix a type of block_device_mapping_v2 in a comment
Change-Id: I9c74402fbc4b2390b64265c6f174bc7e343900cc
Closes-Bug: #1804198
2018-11-21 13:39:59 +09:00
Zuul
58b3ac457a Merge "Replace MB with MiB" 2018-10-27 05:55:20 +00:00
Alessandro Pilotti
3a8d09ec77 Fixes Python3 issue in decoding password
The 'nova get-password' command shows a passowrd as bytes
instead of string in Python 3 currently.
It should be shown as string.
So fix it.

Co-Authored-By: Takashi Natsume <natsume.takashi@lab.ntt.co.jp>
Change-Id: Ibcfb071fcc3c74535b800295ec95ca5ec8bc3c9b
Closes-Bug: #1794167
2018-10-26 11:06:44 +09:00
Zuul
9abb67c8f4 Merge "Deprecate the unused instance-name" 2018-10-25 04:29:28 +00:00
Tao Li
910201f201 Deprecate the unused instance-name
The '--instnace-name' option exists in nova CLI for a long time,
but it is not used, so we deprecate it firstly and will remove it in
T release.


Change-Id: I0c3d611fc322ae2c9f28ce3845b1c08eaab69485
Closes-Bug: #1788182
2018-10-25 00:54:05 +00:00
Takashi NATSUME
80b4286981 Replace MB with MiB
Change-Id: Ie5bd325d8e0f7e9af76c1ddae1d679b0e797c84b
2018-10-22 07:11:25 +00:00
Matt Riedemann
578b37f994 Recommend against using --force for evacuate/live migration
This copies the same warnings from the API reference change
I85e7c2677f4d5eccc1e7f349de06960b53ef148d to the CLI help
for the various evacuate/live migrate commands. It also
mentions that if a host is not specified, one is selected
by the scheduler (which is what we really want people doing).

Given blueprint remove-force-flag-from-live-migrate-and-evacuate
we really want to discourage people from using the --force
flag.

Change-Id: I15ef933cc09947e2bb3fb7bf17b15735171a9bec
2018-10-17 16:32:42 -04:00
Zuul
f0c63de21d Merge "Add support for microversion 2.67: BDMv2 volume_type" 2018-10-16 03:37:42 +00:00
Zuul
3881e0ba34 Merge "Enable split logging for cinder-novaclient interaction" 2018-10-15 00:45:12 +00:00
Matt Riedemann
4fef02de71 Add support for microversion 2.67: BDMv2 volume_type
This adds the nova boot command and python API binding
support for creating a server with block device mappings
defined using a specific volume type.

Depends-On: https://review.openstack.org/606398/
Depends-On: https://review.openstack.org/#/c/610349/

Part of blueprint boot-instance-specific-storage-backend

Change-Id: I484ee065119b5783db212ea64efa60e87c40338c
2018-10-14 05:34:24 -04:00
Takashi NATSUME
0fdb154d9c doc: Start using openstackdoctheme's extlink extension
This ensures we have version-specific references to other projects [1].

[1] https://docs.openstack.org/openstackdocstheme/latest/#external-link-helper

Change-Id: I3b9db8b71c082dd5f8d0564a9cdfdb2fa6dc5ed6
2018-10-09 12:22:17 +09:00
Zuul
c7066745b1 Merge "Update the CLI reference" 2018-10-08 12:31:56 +00:00
Zuul
d5f912c971 Merge "Follow up "Fix up userdata argument to rebuild"" 2018-10-08 12:31:55 +00:00
Zuul
73b15b6d0d Merge "Update the contributor guide" 2018-10-08 11:31:17 +00:00
Takashi NATSUME
47dc339ab9 Follow up "Fix up userdata argument to rebuild"
This patch is a follow-up patch for
I9752d849aa0e6cf608db0def3ca89565cff4debc.

* Add checking a message of an exception in the unit test
* Add 'with' statement when opening a file
* Fix descriptions in the release note

Change-Id: I2c399490f320a202b41a8f8d36710a36621c4853
2018-10-04 12:22:04 +09:00
Zuul
bfbec25e27 Merge "Fix up userdata argument to rebuild." 2018-10-03 06:47:08 +00:00
Takashi NATSUME
3b26956819 Update the CLI reference
Update the CLI reference according to the latest CLIs.

The CLI reference (doc/source/cli/nova.rst) has been imported
from openstack-manuals since If19cfcafc90fddb930c124a5b9845d4eae1f6093.
We can update the CLI reference synchronously with changing the CLIs
currently.
So remove the description of nova CLI version in the reference.

Change-Id: Icb97def5e4d65a31add7c60c205d5f9f0dfc4520
Closes-Bug: #1795283
2018-10-02 12:04:08 +00:00
Takashi NATSUME
f22685f588 Update the contributor guide
Add missing tox targets in contributor/testing.rst.
Replace the launchpad link to nova project with
the launchpad link to python-novaclient project
in contributor/index.rst.

Change-Id: I1b3736f25e59669624331d8f86820a45181c6760
Closes-Bug: #1795353
2018-10-02 12:03:35 +00:00
Sam Morrison
cac7351b0e Fix up userdata argument to rebuild.
This was using the name of the file as user data as opposed
to the content of the file.

Change-Id: I9752d849aa0e6cf608db0def3ca89565cff4debc
Closes-bug: #1794419
2018-10-02 20:17:30 +10:00
Takashi NATSUME
98b088286d Fix test_instance_action functional test failure
Fix an intermittent failure of
test_list_instance_action_with_changes_before method
of the TestInstanceActionCLIV266 class.

Change-Id: Ie898d9590e1701476eadf4895bce7874d989175a
Closes-Bug: #1795392
2018-10-02 03:48:49 +00:00
Zuul
25ced5b95c Merge "Add support changes-before for microversion 2.66" 2018-09-25 06:24:18 +00:00
zhangbailin
4464a88737 Add support changes-before for microversion 2.66
This adds the changes-before filter to the servers,
os-instance-actions and os-migrations list for
filtering resources which were last updated before
or equal to the given time. The changes-before filter,
like the changes-since filter, will return deleted
server resources.

Depends-On: https://review.openstack.org/599276/
Part of bp support-to-query-nova-resources-filter-by-changes-before

Change-Id: I7c6ea00303374d605bda8ef1b62c5de1b4567696
2018-09-24 15:14:18 -04:00
Stephen Finucane
fd9670bd41 docs: Add redirects
These were missed for some reason. Let's add them now.

While we're here, we add the '-d DOCTREE_DIR' argument to our
'sphinx-build' call to handle Sphinx 1.8's change in behavior for where
doctrees are output.

Change-Id: I5c862a74f92a44bf5248f858e26826eef76c11f0
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-09-24 15:18:06 +01:00
Takashi NATSUME
9d8eda8b82 Follow the new PTI for document build
- Follow new PTI for docs build
- Add sphinxcontrib.apidoc to replace pbr autodoc

REF:
https://governance.openstack.org/tc/reference/project-testing-interface.html
http://lists.openstack.org/pipermail/openstack-dev/2017-December/125710.html
http://lists.openstack.org/pipermail/openstack-dev/2018-March/128594.html

Change-Id: Ic66fe4d5488c7777439a416fbf86d37af807804d
Closes-Bug: #1792115
2018-09-13 04:57:03 +09:00
Zuul
8128ebbdd9 Merge "Improve the description of optional arguments" 2018-09-12 11:25:48 +00:00
Zuul
c5ac62f4ef Merge "Cleanup zuul.yaml" 2018-09-11 19:09:30 +00:00
Zuul
32206f4374 Merge "add lib-forward-testing-python3 test job" 2018-09-11 19:09:28 +00:00
Zuul
ce7c98caf0 Merge "add python 3.6 unit test job" 2018-09-11 19:09:26 +00:00
Zuul
32149a7f0c Merge "switch documentation job to new PTI" 2018-09-11 18:56:44 +00:00
Zuul
1d10465e1a Merge "import zuul job settings from project-config" 2018-09-11 18:43:37 +00:00
Takashi NATSUME
72b4441fe1 Improve the description of optional arguments
This patch is a follow-up patch for
Ib4ce831a5031459d350fa73601e878e7b319640f.

Improve the description of optional arguments
in the CLI reference and help text.

Change-Id: I6313b8a584385daa7e9fbd558d431faa43015449
2018-09-12 00:35:34 +09:00
Andreas Jaeger
8e1849eff1 Cleanup zuul.yaml
Couple of cleanups:
* Use openstack-lower-constraints-template, remove jobs that are part
  of templates.
* Use openstack-tox-cover template, this runs the cover job
  in the check queue only. Remove post job.
* Sort list of templates.

Change-Id: I0f186ba675ecb5802ef6a84ac05727a8621d3768
2018-09-10 22:24:43 +02:00
Takashi NATSUME
b5a4a47977 Add missing options in CLI reference
Add the following missing options in the CLI reference.

* nova instance-action-list
  - marker
  - limit
  - changes-since

* nova migration-list
  - marker
  - limit
  - changes-since

Change-Id: Ib4ce831a5031459d350fa73601e878e7b319640f
Closes-Bug: #1791125
2018-09-11 03:14:04 +09:00
Doug Hellmann
82474d0213 add lib-forward-testing-python3 test job
This is a mechanically generated patch to add a functional test job
running under Python 3 as part of the python3-first goal.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I58ae5f91517700745073cc06ead073ba13ac923d
Story: #2002586
Task: #24315
2018-09-09 05:56:07 -04:00
Doug Hellmann
d46a8e6501 add python 3.6 unit test job
This is a mechanically generated patch to add a unit test job running
under Python 3.6 as part of the python3-first goal.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: Ib497e0a8cec7656925441c252f0eda96ad32b9b9
Story: #2002586
Task: #24315
2018-09-09 05:56:04 -04:00
Doug Hellmann
1b6ae4b11e switch documentation job to new PTI
This is a mechanically generated patch to switch the documentation
jobs to use the new PTI versions of the jobs as part of the
python3-first goal.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I7fa9df3d37285ee2427a4275b738b7c7e69a9177
Story: #2002586
Task: #24315
2018-09-09 05:55:59 -04:00
Doug Hellmann
5b9c4af775 import zuul job settings from project-config
This is a mechanically generated patch to complete step 1 of moving
the zuul job settings out of project-config and into each project
repository.

Because there will be a separate patch on each branch, the branch
specifiers for branch-specific jobs have been removed.

Because this patch is generated by a script, there may be some
cosmetic changes to the layout of the YAML file(s) as the contents are
normalized.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I84676a89b612b7ac4e925534ba81203048fd2866
Story: #2002586
Task: #24315
2018-09-09 05:55:56 -04:00
openstack
05e287fa9f Enable split logging for cinder-novaclient interaction
This patch ensures that log messages[1][2][3] are logged only when
keystoneauth=DEBUG is enabled in cinder.conf. This will also enable
us to consume split_logger config option [4] when enabled in cinder
without making any additional changes in client code.

[1] REQ: https://review.openstack.org/#/c/505764/8/keystoneauth1/session.py@391
[2] RESP: https://review.openstack.org/#/c/505764/8/keystoneauth1/session.py@422
[3] RESP BODY: https://review.openstack.org/#/c/505764/8/keystoneauth1/session.py@454
[4] https://review.openstack.org/#/c/568878/

Closes-Bug: #1782134
Change-Id:I3c47b5249141b3f05b2f54984bb5b1d7801a02bc
2018-08-24 12:49:36 +00:00
Zuul
c2d0fb7098 Merge "Replace os-client-config to openstacksdk" 2018-08-15 15:38:56 +00:00
liuyamin
2d023bcb0e Replace os-client-config to openstacksdk
Since now os-client-config has been superceded by openstacksdk[1].
So need to replace the os-client-config.

[1]:https://docs.openstack.org/os-client-config/latest/

Change-Id: Ia0e0671720de4713098e9d0faa1d7dc0c4ae6147
2018-08-14 03:05:18 +00:00
Zuul
9b184080fc Merge "Use uuidutils of oslo.utils" 2018-08-08 18:00:11 +00:00
Takashi NATSUME
46ad782fb0 Use uuidutils of oslo.utils
Replace standard uuid library with uuidutils of oslo.utils.

TrivialFix
Change-Id: Ibb6ec8b56a404685d9727f1b771dbff178fdecdf
2018-08-08 15:12:28 +09:00