4952 Commits

Author SHA1 Message Date
Zuul
73d56bc8d4 Merge "Add a few selectable fields to the "openstack server list" output" 2020-11-18 13:28:55 +00:00
Zuul
7d624cc78a Merge "trivial: Document removal of support for agents" 2020-11-18 01:22:02 +00:00
Zuul
bba5725085 Merge "Switch 'openstack keypair' ops to use SDK" 2020-11-17 14:53:12 +00:00
Zuul
2005a1e833 Merge "Allow to resize in-use volumes" 2020-11-17 14:51:42 +00:00
Stephen Finucane
a5101a4139 trivial: Document removal of support for agents
We can't remove these commands for a long time, given OSC's intention to
support multiple releases of OpenStack, but we can at least indicate to
users that this thing might not work anymore.

Change-Id: I9093cc1197a0287984d83e2020fba100d0c958b3
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-11-17 11:44:31 +00:00
Zuul
24edeb24a6 Merge "tests: Remove 'agent' functional tests" 2020-11-16 21:37:18 +00:00
Stephen Finucane
ebaf0eae2c tests: Remove 'agent' functional tests
The 'os-agents' API was recently removed from nova [1]. Remove the
functional tests, since they will always fail going forward but will
continue to run on older stable branches.

Also Squeeze https://review.opendev.org/#/c/762559/ inside, since those
2 are simultaneously blocking gate

[1] https://review.opendev.org/#/c/749309/

Change-Id: I0bf7d4c0ba2a9d4637db0d209d8d52163d772f12
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-11-16 15:54:27 +01:00
Zuul
ce31c417de Merge "Resolve issues with 'server migration list'" 2020-11-12 11:20:21 +00:00
Dmitriy Rabotyagov
4c0bfb03fc Allow to resize in-use volumes
Since Pike (microversion 3.42) [1] Cinder API allows to resize in-use
volumes. So no reason not to implement it in CLI.

[1] https://opendev.org/openstack/cinder/src/branch/master/cinder/api/openstack/rest_api_version_history.rst#user-content-section-39

Change-Id: I22462a56d261e0a100aac3f27af7be47223edec0
2020-11-11 09:18:49 +00:00
Zuul
e2bd1530cf Merge "functional: Remove test for 'quota set --force'" 2020-11-09 18:50:43 +00:00
Zuul
4d3bad9f19 Merge "Add 'openstack server evacuate' command" 2020-11-09 16:56:19 +00:00
Stephen Finucane
1a5dd4af5b Resolve issues with 'server migration list'
The 'os-migrations' API accepts 'instance_uuid' and 'migration_type'
query string parameters, not 'server' and 'type'. For the former, as the
name would suggest, the value should be a server UUID, not a name.

In addition, this is a list command and therefore should subclass the
'Lister' base class.

Change-Id: I736f5575156fc04d7ada7783a1865ab3b438396f
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-11-09 15:05:54 +00:00
Artem Goncharov
512ba114a1 Switch 'openstack keypair' ops to use SDK
Let's continue our journey and start using SDK for the keypair
operations

Depends-On: https://review.opendev.org/#/c/761883/
Change-Id: Id411e70b8e1a79c0e88a0e22be7ff37e5c30fcda
2020-11-09 13:14:53 +01:00
Stephen Finucane
ffd7e93961 functional: Remove test for 'quota set --force'
Change I1d1ac1ac46f49f64794ffc8631e166935537966c introduced the 'quota
set --force' parameter to force set nova quotas. As part of that fix, we
introduced a functional test, 'QuotaTests.test_quota_set_force' that
works by attempting to set the 'limit' of the quota for instances to the
current usage ('is_use') minus one.

This test is flawed. It doesn't create any instances so when it fires by
itself, it will always set the 'limit' to 0. When it fires at the same
time as other tests (remember, we run tests in parallel), notably tests
that rely on booting instances, it can cause other tests to fail with
the following error:

  Quota exceeded for instances: Requested 1, but already used 0 of 0
  instances (HTTP 403)

We could attempt to work around this by creating a new project and using
that project to fiddle with quotas. That's a lot of work though, and the
returns are questionable: the 'quota set' command is an admin-only
command by default and the '--force' parameter should almost never be
used. Simply remove this test.

Change-Id: Ic07ff6f4a7c1c27852c892eb906bb144aae91788
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
Story: #2008327
Task: #41225
2020-11-06 17:40:13 +00:00
Stephen Finucane
0a7f2692c6 Remove references to Python 2.7
We don't support it anymore. This is just noise now.

Change-Id: I3640e7d8e520db69f83f95e9c7759279f7c15008
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-11-05 14:15:37 +00:00
jay
311f4130d2 Add a few selectable fields to the "openstack server list" output
Added ``-c project_id | user_id | created_at`` to ``openstack server list``
    command to get these columns as an output.

Change-Id: I18991adf899c7b72c98bb89871bf0715d35943f0
Story: 2007925
2020-11-05 14:01:12 +01:00
Zuul
cb6659d7cd Merge "Compute: Add user id support for keypair" 2020-11-04 00:28:41 +00:00
Zuul
71cdb113fe Merge "Add 'openstack server migration list --type' option" 2020-11-03 12:58:49 +00:00
Zuul
a40d22f1ed Merge "Fix formatting of the flavor properties" 2020-11-03 10:07:13 +00:00
Zuul
4cdc953888 Merge "Add support for 'keypairs list --project' parameter" 2020-11-02 17:23:23 +00:00
Sean Mooney
01eb4e8393 Add 'openstack server evacuate' command
This change adds a new 'openstack server evacuate' command to provide
parity with the 'nova evacuate' command. The term "evacuate" is
notoriously poor, in that it implies the instance is moved rather than
recreated, but it is retained since people are familiar with it now.

Change-Id: I1e32ca51036c501862d8e89b3144a9695d98a06f
2020-11-02 17:08:17 +00:00
Zuul
2ffd06b3d5 Merge "Switch console url show operations to SDK" 2020-11-02 17:00:51 +00:00
Artem Goncharov
ad3369ed1f Fix formatting of the flavor properties
Do not stringify flavor properties to allow proper output formatting to
json/yaml/etc

Change-Id: I9f4c42acb85b726af87123134dd19de98fe95074
2020-11-02 15:09:09 +01:00
He Jie Xu
17f641e1c3 Compute: Add user id support for keypair
This patch adds functionality of specific the user id when create,
delete, show and list keypairs.

Change-Id: Ib826f1f4f5a73d1875ba0f02e124b3222c4d05ed
Co-Authored-By: tianhui <tianhui@awcloud.com>
2020-11-02 12:55:04 +00:00
Zuul
7fdbc6b8af Merge "Add support for 'keypairs list --user' parameter" 2020-11-02 12:06:41 +00:00
Zuul
987af4e390 Merge "trivial: Rework 'CreateServer' function" 2020-10-30 17:30:35 +00:00
Stephen Finucane
7c239403e9 trivial: Rework 'CreateServer' function
This rather complex function has had stuff tacked on over the years.
Help make working with it a bit easier through liberal application of
whitespace and some nicer indentation. Some option help text is improved
based on changes to modern nova.

Change-Id: I8154dd395dd904c3bcd180a7d0f9037b7e0be64f
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-10-29 11:43:23 +00:00
Zuul
c4e7a7e803 Merge "Replace deprecated UPPER_CONSTRAINTS_FILE variable" 2020-10-28 22:18:58 +00:00
Elod Illes
5b04a86d1f Replace deprecated UPPER_CONSTRAINTS_FILE variable
UPPER_CONSTRAINTS_FILE is deprecated and TOX_CONSTRAINTS_FILE is
the new environment variable name that replaces it [1].

[1] https://zuul-ci.org/docs/zuul-jobs/python-roles.html#rolevar-tox.tox_constraints_file

Change-Id: Ic0d2dcf20f7929733deb10a275e5d67f9627428f
2020-10-28 12:37:58 +01:00
Artem Goncharov
e05d39abb5 Switch console url show operations to SDK
Switch from using novaclient to SDK for openstack console url show operation.

Depends-On: https://review.opendev.org/756286
Change-Id: Ibe247825148788c549c2c1e991aae92338cdf557
2020-10-24 10:19:52 +02:00
Stephen Finucane
5f650853f7 Remove references to setuptools
Newer versions of cliff and stevedore use importlib rather than
setuptools to work with entry points. Replace any references to
"setuptools' entry points mechanism" with "Python's entry points
mechanism".

Change-Id: Iae36155685ee37ab5e38a0c173110a5ece33d05d
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-10-22 09:52:57 +01:00
Zuul
66f5fa18d4 Merge "Remove the unused coding style modules" 2020-10-22 04:47:31 +00:00
Zuul
deae091f78 Merge "Validate 'server group create --policy' option" 2020-10-21 20:05:12 +00:00
Zuul
0228790024 Merge "Cleanup of 'server migration list' command" 2020-10-21 19:57:47 +00:00
Zuul
eb75c44656 Merge "Switch openstack console log show operation to use OpenStackSDK" 2020-10-21 16:19:21 +00:00
wu.chunyang
f464bba792 Remove the unused coding style modules
Python modules related to coding style checks (listed in blacklist.txt in
openstack/requirements repo) are dropped from lower-constraints.txt
they are not needed during installation.

Change-Id: Id735af397e8d41ad3ff583386844d4131fc9e12c
2020-10-21 23:44:33 +08:00
Zuul
77a45fe685 Merge "Compute: Add tag support for server add fixed ip" 2020-10-15 17:42:50 +00:00
Zuul
d59057ad3d Merge "Compute: Add tags support for server" 2020-10-14 17:38:33 +00:00
Zuul
96658a3116 Merge "Restore behavior of image create with same name." 2020-10-14 09:59:54 +00:00
Stephen Finucane
5645fad762 Add support for 'keypairs list --project' parameter
It would be lovely to do this server side but doing so requires a new
microversion, a blueprint and a spec. This is less performant but should
do the trick for the odd time users want to do this.

Change-Id: I26e7d38966304dd67be5da8ed0bb24f87191b82f
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-10-14 10:27:05 +01:00
Stephen Finucane
98a0016cfa Add support for 'keypairs list --user' parameter
This has been supported by nova and novaclient since the veritable dark
ages. Add it to OSC.

Change-Id: Ifc95e7dd6c00807c80e87e10046ab154d0989014
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-10-14 10:25:50 +01:00
tianhui
2f76bfa3a6 Compute: Add tags support for server
Change-Id: If065602792958ff0145ae9f2e05f5b7a3177905c
Story: 2002006
Task: 19641
2020-10-14 09:53:26 +01:00
Zuul
6216025e9d Merge "Compute: Add tag support for server add volume" 2020-10-14 03:46:06 +00:00
Zuul
f083d42972 Merge "Add 'server migration force complete' command" 2020-10-14 03:46:00 +00:00
Zuul
91027a501f Merge "Add 'server migration abort' command" 2020-10-14 03:45:54 +00:00
Zuul
247ca75d26 Merge "compute: Add --password option for openstack server create" 2020-10-13 23:26:25 +00:00
Zuul
2eeab20eca Merge "Always display direction for security group rules" 2020-10-13 23:26:24 +00:00
Zuul
73765da310 Merge "Compute: Add 'keypair create --type' parameter" 2020-10-13 14:53:12 +00:00
Stephen Finucane
ab0b1fe885 Validate 'server group create --policy' option
We were documenting that some of these policies were only supported with
specific microversions, however, we weren't actually enforcing that,
leading to a poor user experience. Correct this.

Change-Id: Ic3c555226a220efd9b0f27edffccf6c4c95c2747
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-10-13 15:35:21 +01:00
Stephen Finucane
bf35f04682 Add 'openstack server migration list --type' option
Another gap with novaclient closed.

Change-Id: Id3ca95ceda6f438fa72496ab9ab15ac09bb64fa5
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-10-13 15:14:09 +01:00