2196 Commits

Author SHA1 Message Date
Jenkins
527df930be Merge "Encode unicode filter arguments for server list" 2015-09-19 03:24:39 +00:00
Jenkins
bfe969862b Merge "Updated from global requirements" 2015-09-18 19:23:51 +00:00
Jenkins
2dff4b05dd Merge "[docs] Fix length of underline" 2015-09-18 18:33:03 +00:00
OpenStack Proposal Bot
ac6a04864a Updated from global requirements
Change-Id: I991327116276dc2e4f2d7a4b52d293305caa5b4e
2015-09-18 16:42:28 +00:00
Richard Jones
485201453a Encode unicode filter arguments for server list
Previously unicode arguments were not encoded so unicode
exceptions were thrown when the arguments were URL encoded.

Change-Id: I69a5ac8dcf584ad5b5604caf3c4cb16bb59d3fe3
Partial-Bug: 1472999
2015-09-18 11:45:50 +10:00
Jenkins
64c8039c1e Merge "Show reserved status for a fixed_ip if available" 2015-09-17 21:26:49 +00:00
Jenkins
4d5cfdead0 Merge "Fix nova bash-completion needs authentication" 2015-09-17 20:50:44 +00:00
Andrey Kurilin
420782cc01 [docs] Fix length of underline
Title length must match the underline

Change-Id: Ia7a2bf54a6697c63c423bacd53dfb125b9c620f6
2015-09-17 16:07:11 +03:00
OpenStack Proposal Bot
5c59684ae7 Updated from global requirements
Change-Id: Iadb3dfd4b07a1eef7a31799d3cc1239aaade08b2
2015-09-17 12:16:56 +00:00
Atsushi SAKAI
b1204446ef Fix nova bash-completion needs authentication
CLI-Reference generator requires
   (openstack-doc-tools/bin/doc-tools-update-cli-reference)
  that command line help and bash-completion running without authentication.

  For this purpose, remove authentication check in command and its test.
    Fix nova bash-completion works without authentication.
    Fix nova bash-completion test without setting authentication infomation.

  Define skip_auth for descriminate "nova bash-completion" and do_help.

Change-Id: Ic1a7f84b1b9cb7e8be6721c1b8096f49e9e9ab33
Closes-Bug: #1495424
2015-09-17 09:20:48 +09:00
Matt Riedemann
5fdb861ad4 Show reserved status for a fixed_ip if available
Commit 8886590f30daf736ae30a95b3e4a77cb586d4f02 adds the v2.4
microversion to nova so that we can get back the reserved value of a
fixed IP.

This change adds support to novaclient to display the reserved status
from the fixed_ip resource if it's available in the response.

Related blueprint show-reserved-status-in-os-fixed-ips-api

Change-Id: Idf3df1728ba87006d1b0f82a1c01712202670e0a
2015-09-16 14:21:37 -07:00
Jenkins
0820a9e793 Merge "Remove redundant help command test and commonize" 2015-09-16 15:53:16 +00:00
Jenkins
e1346865db Merge "Modify "nova keypair-show" Positional arguments help information" 2015-09-15 20:55:06 +00:00
Jenkins
fb47954802 Merge "Add response message when the state of a server is reset" 2015-09-15 20:55:03 +00:00
Jenkins
101d53dc66 Merge "Fix unicode issue in shell.main() error handling" 2015-09-15 20:23:05 +00:00
Jenkins
47838395d7 Merge "Fix mistakes in comments" 2015-09-15 15:48:03 +00:00
Victor Stinner
48f9c5a046 Fix unicode issue in shell.main() error handling
shell.main() uses safe_encode() to encode the exception name and
exception message. On Python 3, it displays:

   ERROR (b'Exception'): b'message'

instead of:

   ERROR (Exception): message

Don't encode exception name and message on Python 3. Use
exception_to_unicode() of oslo_utils.encodeutils to get the exception
message as Unicode. On Python 2, let print() encodes the Unicode to
the encoding of sys.stderr.

Blueprint nova-python3
Change-Id: Ib5568546d2aedb2b28c05d840b9ba34f697384ec
2015-09-15 09:53:15 +02:00
melanie witt
b4e9af99d7 Remove redundant help command test and commonize
This is a follow up patch to https://review.openstack.org/#/c/221488/
which added unit tests for 'nova -h' and 'nova --help' and commonized
some code. It was missed that a test for 'nova' without any options or
subcommands already existed as "test_help_no_options"

This patch also refactors "test_help_on_subcommand" use the common
"_test_help" function since that was also missed.

Change-Id: Iccaf91207ba35001c8f58abb550cd1c3be542b38
2015-09-15 00:20:23 +00:00
venkatamahesh
e9f1391bf8 Fix the homepage url in setup.cfg
Link for home-page is https://www.openstack.org
but instead of it source tree link is there
So it is changed

Change-Id: Ie788e5a6c66d71b59cdedf5fcf14725181983629
2015-09-13 14:44:56 +05:30
Wang Wei
6f58fa2c9a Fix mistakes in comments
Each can only delete an aggregate by API,
so, change 'aggregates' to 'aggregate'

Also, change 'Set a aggregate metadata' to
'Set aggregate metadata'

Change-Id: Ieb4a8b2445678da8741794613aede948ba51e5ce
2015-09-12 09:05:36 +08:00
Jenkins
37d1e29a0b Merge "make sure os_password is set for auth_plugins" 2015-09-11 17:06:35 +00:00
Jenkins
382af52544 Merge "Add unit tests for different help commands" 2015-09-11 11:30:29 +00:00
Xiaowei Qian
f636481f01 Modify "nova keypair-show" Positional arguments help information
CLI "nova keypair-show <keypair>", Positional arguments:
  <keypair> Name or ID of keypair
But in fact, it does not support ID,when using ID, the error is as follows:
[root]# nova keypair-show 631
ERROR (CommandError): No keypair with a name or ID of '631' exists.
So it is needed to change the Positional arguments help information
from "Name or ID of keypair" to "Name of keypair".

Change-Id: I4cd022a6aa1ca937e7aeb33847dc3ce2d6d5690e
Closes-Bug: #1493212
Signed-off-by: Xiaowei Qian <qianxw.fnst@cn.fujitsu.com>
2015-09-11 00:55:53 +00:00
Jenkins
31d4e026b4 Merge "[BugFix] Change parameters for legacy bdm" 2.29.0 2015-09-10 23:58:15 +00:00
Daniel Wallace
b547a3da50 make sure os_password is set for auth_plugins
os_password is not set anywhere for auth_plugins.  It is only set for
keystone sessions.  This makes sure that it gets set before being passed
to Client.

Closes-Bug: #1493977
Change-Id: I94421fd6fa58be391dfe8a9a14479bb4c17c5231
2015-09-10 16:50:28 -05:00
Jenkins
d552dab88f Merge "Set api_version to 2.0 by default for v2.Client" 2015-09-10 18:11:28 +00:00
Jenkins
4d1def5f97 Merge "Deprecate 'novaclient.client.get_client_class'" 2015-09-10 18:11:14 +00:00
Jenkins
b5bffb3d30 Merge "Restrict direct usage of novaclient.v2.client" 2015-09-10 18:11:07 +00:00
Jenkins
5f8754f64d Merge "Fix bugs with rackspace" 2015-09-10 18:10:54 +00:00
Andrey Kurilin
5153dcda80 [BugFix] Change parameters for legacy bdm
`_parse_block_device_mapping` method was design to support both
bdm v1 and v2. The implementation is based on the fact that API side
ignores unknown/incorrect parameters, so `_parse_block_device_mapping` compose
equal parameter for bdm v1 and bdm v2. Since Nova V2.1 contains schema checks,
such implementation stoped working.
Despite the fact that novaclient.v2.servers contains separate logic for bdm v2,
we can make `_parse_block_device_mapping` works only with legacy bdm and
in future patches make it works for both bdm v1 and bdm v2.

Change-Id: I37c00ac77b1a3b500221d779533532e9f43e5277
Closes-Bug: #1491737
2015-09-10 20:44:49 +03:00
Jenkins
6ecc81b89b Merge "Option to specify max servers for live evacuate" 2015-09-10 16:21:06 +00:00
Andrey Kurilin
599ee29536 Set api_version to 2.0 by default for v2.Client
`novaclient.v2.client.Client` class should use V2.0 API by default, if
api_version argument is empty.

Change-Id: Id44a68f5d52f6f6055c3abe520bb916329552d09
2015-09-10 15:55:29 +03:00
Andrey Kurilin
147a1a6ee4 Deprecate 'novaclient.client.get_client_class'
This method is redundant and blocks versioned client classes to change
interface. `novaclient.client.Client` should be used instead.

Releated-Bug: #1493576
Change-Id: I73cea2c6062419d75646e9239c6194f4d1ffd2b1
2015-09-10 15:55:26 +03:00
Andrey Kurilin
a96e9d57c5 Restrict direct usage of novaclient.v2.client
A lot of project uses incorrect import of versioned novaclient client obj
(i.e. novaclient.v2.client.Client). It leads to unability to change
interface of such inner classes.

This patch updates docs to include warning note and add warning message to
`novaclient.v2.client.Client` object.

Change-Id: Ifeba391716d3d51d6a75a53cad405e1ec595e27b
Related-Bug: #1493576
2015-09-10 15:54:38 +03:00
Daniel Wallace
b2221c8a70 Fix bugs with rackspace
not all apis have the versions available

Rackspace api does not open up for querying versions.  This causes it to
still break when using the rackspace-auth-plugin

add tests for api_version Unauthorized

make sure that the list can still run even if the api_version check is
unauthorized.

Closes-Bug: #1493974
Closes-Bug: #1491579
Change-Id: I038b84bad5b747a0688aef989f1337aee835b945
2015-09-09 14:47:20 -05:00
Jenkins
e612205ab8 Merge "Enable i18n with Babel." 2015-09-08 21:39:19 +00:00
melanie witt
d0b44893ac Add unit tests for different help commands
Related-Bug: #1491677

Change-Id: I7e6b74e60dafa0e869a5b3355793cda1cf08c389
2015-09-08 20:11:17 +00:00
Mark Doffman
f7a26601b2 Enable i18n with Babel.
Add Babel commands to setup.cfg. Create the first .pot file with current
translatable strings using `python setup.py extract_messages`.

Co-Authored-By: Matt Riedemann <mriedem@us.ibm.com>

Change-Id: I57804496d1ec67b566b350941e71206903dd8d1d
Closes-Bug: #1492444
2015-09-08 10:10:25 -07:00
Ramaraja
ca031f9915 Fix nova --help needs authentication
Added --help,-h in do_help flag so that authentication will not be prompted.

Change-Id: Iafb766304eeda58eff0c92b87a127018820832fd
Closes-Bug: #1491677
2015-09-07 15:45:29 +05:30
Jenkins
9e15b3d7c0 Merge "[Bug-Fix] Update requests body for quota-update" 2.28.1 2015-09-04 17:33:13 +00:00
Andrey Kurilin
6fc3a943e6 [Bug-Fix] Update requests body for quota-update
Update quotas API call doesn't accept parameter "tenant-id".

Change-Id: I1cbc6088c5deeb32e4e98ef1ced5f83ce71fe3ab
Closes-Bug: #1492242
2015-09-04 17:49:27 +03:00
Jenkins
5d5060375d Merge "Adds missing internationalization for help message" 2015-09-04 00:34:38 +00:00
Bartosz Górski
d970de480d Adds missing internationalization for help message
Change-Id: Iecb3eaa791969da422ea062148b58645457f8aab
Closes-Bug: #1491492
2015-09-03 21:53:53 +00:00
Sean Dague
e4b0d46c4b workaround for RAX repose configuration
The RAX Repose environment is blocking access to the API version
information by local policy, returning a 401 before we even get to
Nova itself. While this in clearly incorrect behavior, it is behavior
in the field, and we should not break all our users on that cloud.

This catches the 401 and translates that so that it's the equivalent
of only supporting v2.0. We will be taking these API calls to defcore,
and intend to remove this work around once that is done.

Change-Id: I2072095c24b41efcfd58d6f25205bcc94f1174da
Related-Bug: #1491579
2.28.0
2015-09-03 14:13:33 -04:00
Sean Dague
5869abc531 fix novaclient functional tests for new devstack config
The novaclient functional tests assumed computev21 as a type in the
service catalog. We're defaulting compute in devstack to v21 now, so
this no longer works. This is probably far too coupled to devstack
atm, however until we get to unversioned service catalog, this is what
we need to do.

Change-Id: Ifb0056924b20f62d75d13a7b4aae829df61a5396
2015-09-03 13:19:28 -04:00
Sean Dague
c915757ed5 Don't assume oscomputeversions is correctly deployed
The paste pipeline that's "above" the /v2/ and /v2.1/ urls is the
oscomputeversions dispatcher, which should provide 300 redirects to
versions in question. Previously the code that was trying to discover
information about the current version did so via a GET of something
that looked like /v2. On an upstream compatible OpenStack this
actually triggers a 300 and redirect to /v2/ for the real answer.

On deployed public clouds, oscomputeversions is sometimes not deployed
at all, or front end blocking by the load balancer does
weirdness. Sometimes with a 401, sometimes a hang.

This fixes the way that first request is made that should avoid the
300 redirect entirely. The code probably should have done this
originally, but it was tested with upstream configuration that worked
fine in this case.

This fix is tested against HP Cloud (the only pub cloud I have creds
with). Before this fix "nova list" hangs trying to get the supported
versions, after the fix it works as expected.

Change-Id: I1692380fe8d340e5c044f46dd0b103c7550d2c7d
Closes-Bug: #1491579
2015-09-03 13:19:28 -04:00
Matt Riedemann
eaf1e56b21 Update path to subunit2html in post_test_hook
Per:

http://lists.openstack.org/pipermail/openstack-dev/2015-August/072982.html

The location of subunit2html changed on the images in the gate
so update the path used in the post_test_hook.

Long-term we should just use what's in devstack-gate.

Change-Id: I5e50e7d7ad845aba26403df1df412c0a139a6dc7
Closes-Bug: #1491646

--------------
squashed with:
--------------

Don't pass null device when attaching a volume

The v2.1 API schema rejects null device values in an
os-volume_attachments request, so only include the device in the request
if one is specified on the command line.

Closes-Bug: #1491325

Change-Id: I4fa4019f19f9af6ff350db2fb6e524fa8570a6f3
2015-09-02 19:08:09 -07:00
Artom Lifshitz
3d9c01b2d3 Option to specify max servers for live evacuate
The current behaviour of live evacuate is to naively request that all
servers on the hypervisor be evacuated. The more VMs are migrated
simultaneously, the more bandwidth is required. Once a certain number
of migrating VMs is reached, there is not enough bandwidth to cope
with the rate at which they dirty their memory. The migrations will
thus never complete.

The correct solution to this would be a whole lot of work on the Nova
side. As a stopgap measure, this patch introduces a --max-servers
option to host-evacuate-live. With this option, the user can control
the number of VMs that are live-migrated at the same time, thus
allowing the user to avoid the dirty memory scenario described above.

Change-Id: I17bad5f3253d6657fc1e6610159fc8e3921e6ea4
2015-09-02 17:13:47 +00:00
Jenkins
893bf9313c Merge " Allow to reboot multiple servers" 2015-09-01 15:57:50 +00:00
Jenkins
fa0c063d53 Merge "Add method for better random name" 2.27.0 2015-08-31 22:07:08 +00:00