The unit test of "compute service list" only checked the
"Disabled Reason" columns and its data. It is not enough.
This patch change the test to check all datas in the list.
Also, this patch modify the "Id" to "ID" in this command.
Change-Id: I988fd6365f2652185dd96d9417f294eba9c31cd9
"Host set" command cannot work. Because:
1.Host has no 'ID' attribute, so 'ID' attribute cannot be found
in "host set" command.
2.value "True" and "Flase" are invalid in updata() method of host.
3.Some update functionalities is not supported in host API now.
This patch solves the problems 1 and 2 in OSC. But the problem 3
is a API problem and can't be solved in OSC, only XenServer driver
support to set enable/disable and maintenance host, it is a normal
problem.
After this patch the output of "host set" command is:
The requested functionality is not supported. (HTTP 501)
(Request-ID: req-14031fce-8c90-48a0-8492-dc8e3dd349f3)
Just the same as the "host-update" command in novaclient.
Change-Id: Ibe94c4d3d492d3d63355de803810edb988e1b4e9
Closes-Bug: #1594689
Add ``--project`` and ``--project-domain`` options to the
``flavor create`` command. We can use these options to add
the flavor access to a givin project when we create the flavor.
Change-Id: Ic1907272c1d1ae526f9c9e86f32ba06c6da147c0
After this patch, all set/unset commands will return normally
when nothing specified.
Change-Id: Id94d0329faa1a674006a9aae901f834b41917317
Close-bug: #1588588
Support bulk deletion and error handling for "aggregate delete"
and "flavor delete" commands.
Change-Id: I3f6105cbeeab1c9f8cd571c63ce0e7ac3d4252b3
Partially-Implements: blueprint multi-argument-compute
Partial-Bug: #1592906
Use file logger for all command specific logs.
This patch also fixes some usage that doesn't
follow rules in:
http://docs.openstack.org/developer/oslo.i18n/guidelines.html
After this patch, all self.log and self.app.log
will be standardized to LOG().
NOTE: In shell.py, we got the log in class OpenStackShell,
which is also known as self.app.log in other classes.
This logger is used to record non-command-specific logs.
So we leave it as-is.
Change-Id: I114f73ee6c7e84593d71e724bc1ad00d343c1896
Implements: blueprint log-usage
The response data of nova get_xxx_console API is changed
from "console" to "remote_console" in microversion 2.6, and nova
server side API schema verify the spice vnc type to "spice-html5",
update OSC code to apply these change so that OSC can work in
different nova microversion cases.
Change-Id: I3bb4fe057e656209d00d2bb308ac3f7f837cb03f
Closes-Bug: #1590318
The OpenStack LLC copyrights date from before OpenStack was transferred
to the foundation. These appear to be getting copy-pasted to new files
so at least should reflect the correct entity.
Change-Id: I02953d752cb24ead6aa4ad8bfe257a48317c9f13
Aims to evacuate servers from compute host as soon as possible,
operators might set the compute service force down manually.
Novaclient support the behavior, this patch support it in OSC.
Change-Id: I22ff1c5d670c449771fdcb3f4f39cd82f428531a
Closes-Bug: #1589348
Use osc-lib directly for exceptions.
Leave openstackclient.common.exceptions for deprecation period.
Change-Id: Iea3e862302372e1b31ccd27f69db59b4953ca828
This patch adds "--project" option in "flavor set" command to support
for setting flavor access.
Change-Id: I75b473600080d8ab1dd6ad01561c4f989ed3c3bd
Partial-Bug: #1575461
When a server is unexpected state, OSC don't support reset
the server to active or error state, that's supported by
novaclient, and it's an important command for operators, the
patch implement this function.
Change-Id: I3e7800feb192832b0719ef9a353945beb6bfd509
Implements: blueprint server-reset-state
This patch fixes 2 problems:
1. The '\n' should be in the end of a message,
not the beginning.
i.e.:
The original code was:
sys.stdout.write(_('\nError deleting server'))
It will make the output look like this:
[root@tangchen /]# openstack server delete aaa bbb
Error deleting server
Error deleting server[root@tangchen /]#
We change it to:
sys.stdout.write(_('Error deleting server\n'))
Then the output will become:
[root@tangchen /]# openstack server delete aaa bbb
Error deleting server
Error deleting server
[root@tangchen /]#
which is much better.
2. Record the error in log for those who didn't.
Change-Id: I38b00c2321014757970183205f95f026e20a8090
"Server group delete" command supported deleting multi server
groups, but the help message was "Delete an existing server
group", so I change it in this patch.
Change-Id: I05b1a7e3f29b84b9190e7cc05c01734e3daa7a6d