4854 Commits

Author SHA1 Message Date
zhangbailin
b77c28d295 Add server migration list CLI
Add ``openstack server migration list`` to fetch server migrations.

Part of blueprint add-user-id-field-to-the-migrations-table

Change-Id: I15b4a5aca8d0dee59dd293e7b1c7272cdfbeea20
2020-09-24 18:45:13 +08:00
Zuul
51aee432d9 Merge "Support tagging Neutron ports on creation" 2020-09-13 20:34:00 +00:00
Artem Goncharov
99b5adf9c6 Fix gate due to switch to focal
In focal we do not have libffi6.
cffi and greenlet versions in lower-contraints are too old.

Change-Id: Iab3634039845adb649c7fd69d1812b405a61433c
2020-09-11 10:25:56 +02:00
Zuul
15d0bfc185 Merge "Add NUMA affinity policy parameter to "port"" 2020-09-07 16:11:00 +00:00
Miguel Lavalle
67700e6dd9 Support tagging Neutron ports on creation
This change adds support for tagging ports on creation

Co-Authored-By: Slawek Kaplonski <skaplons@redhat.com>

Change-Id: I3148a568664588eb2f529138f984859570c0fca1
Related-Bug: #1815933
2020-09-04 14:30:07 +02:00
Zuul
0566ad66a9 Merge "Allow openstack flavor set to update flavor description using name" 2020-09-03 22:01:16 +00:00
Zuul
95cc05bdf6 Merge "Bypass user and group verification in RemoveRole" 2020-08-13 06:29:54 +00:00
Lance Bragstad
e246732670 Bypass user and group verification in RemoveRole
Keystone let's users remove role assignments that reference non-existent
users and groups. This is nice when keystone backs to an identity store
like LDAP and users or groups are removed.

Previously, openstackclient would validate the user and group existed in
keystone before sending the request to delete the role assignment. This
commit updates the code to bypass that validation so that users can use
IDs to forcibly cleanup role assignments.

Change-Id: I102b41677736bbe37a82abaa3c5b3e1faf2475d5
Story: 2006635
Task: 36848
2020-08-12 12:24:17 -05:00
Zuul
b1477647fa Merge "Add system role assignment tests for users and groups" 2020-08-06 13:37:03 +00:00
Zuul
af28a2f664 Merge "Fix reverted osc-lib interface change" 2020-08-03 14:52:17 +00:00
Rodolfo Alonso Hernandez
454b219564 Add NUMA affinity policy parameter to "port"
Added port NUMA affinity policy parameter to "port create",
"port set" and "port unset" commands.

Change-Id: I48cacab275856af2911829f9b7176bb87fd039b3
Related-Bug: #1886798
2020-07-31 15:18:55 +00:00
mb711d
4e2aefb5fa Delete the testcases that arent needed anymore
The file test_examples.py has never worked since its written and and cli in
the example directory are covered by other functional tests for container,
flavor and object lists and they have better asserts. So, deleting the file

Change-Id: Ib9af40da96e66354fe878e79a80048a58f8dd6fe
2020-07-23 17:08:42 -04:00
Roger Luethi
0a8753dc3e Fix reverted osc-lib interface change
The patch https://review.opendev.org/#/c/673389/ introduced a regression
by changing the osc-lib interface.

Two conflicting attempts to fix the regression were launched:

1) Reverting the patch.

2) The patch https://review.opendev.org/683119 changes the exception
   from the generic CommandError back to a specific Forbidden exception.

   The patch https://review.opendev.org/683118 catches this exception
   and passes on, i.e. re-implements the same behavior as before.

The first idea was implemented, the initial patch reverted. The second
idea was partially implemented. The change in python-openstackclient
(683118) was merged. The change in osc-lib was approved but failed to
merge because the initial change had been reverted.

Now we have again a situation where the exception produced in osc-lib
does not match the exception expected by the caller.

It is unclear if the osc-lib interface will ever get a rebased version
of https://review.opendev.org/683119 merged, so the safest way to
address the issue is to also catch the exception that used to be
thrown before the inital change and is again thrown after the inital
change has been reverted.

Change-Id: I2ea2def607ec5be112e42d53a1e660fef0cdd69c
2020-07-23 20:35:21 +02:00
Felix Yan
82ebddca00 Fix compatibility issue in 5.3
The offending entry point object looks like:
EntryPoint(name='compute', value='openstackclient.compute.client',
group='openstack.cli.base')

Story: 2007917
Task: 40323
Change-Id: I0f3cc62e23efdc14203ce6645581d5ba5dbf7fa0
2020-07-14 08:06:55 -05:00
Lance Bragstad
a8aad9fec8 Add system role assignment tests for users and groups
I was writing some additional functionality and noticed these tests were
missing. This commit adds tests for adding and removing system role
assignments for users and groups.

Change-Id: I30fdc6ec55e1eb1cfa55f4cbf92c3f001d89865f
2020-07-10 08:09:51 -05:00
Zuul
8aed5feab8 Merge "Fix uploading an signed image does not work if private signing key is encrypted" 2020-07-08 17:30:38 +00:00
Zuul
fa517fbf44 Merge "Add a command to trigger entrypoint cache creation" 2020-07-08 17:30:36 +00:00
Zuul
9fb68eca44 Merge "Expose flag for forcing use of import for images" 2020-07-08 17:01:22 +00:00
Alexander Gräb
c06d825635 Fix uploading an signed image does not work if private signing key is encrypted
Change-Id: Ia7c84aa7b840bf92aeb7db7246d14119eb727b03
Story: 2007890
Task: 40269
2020-07-07 13:26:51 +02:00
Zuul
4b5053ac89 Merge "Make volume backup record commands available in v3" 2020-07-07 10:58:15 +00:00
Zuul
42692264f7 Merge "switch to stevedore for entry points" 2020-07-07 06:23:55 +00:00
Zuul
d0741d7853 Merge "Add '--force; parameter to 'openstack quota set'" 2020-07-06 20:50:24 +00:00
Monty Taylor
5c4eb0bf9d Add a command to trigger entrypoint cache creation
stevedore will cache the entrypoint scan when needed. Since we
just installed the things here, do an openstack --help to cause
the entrypoints to get scanned at build time and for the cache
file to be written into the container image.

Change-Id: I73502be6d68c4a38561c9524b4def3c6a6f61ac6
2020-07-06 14:53:50 -05:00
Doug Hellmann
870cf01148 switch to stevedore for entry points
Importing pkg_resources scans every installed distribution to find
all of the entry points. Stevedore is adding a new caching layer using
importlib.metadata, which will not.  Switching to the stevedore should
eventually speed up load times, especially for command line apps. This
change makes the switch now to ensure API compatibility.

We were already using stevedore for tests, so this moves the dependency
from test-requirements.txt to requirements.txt and raises the minimum
version to something more recent.

Change-Id: I3e3632783bc745979b6db73e610df8a77ffaceb0
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2020-07-06 08:44:31 -04:00
Radosław Piliszek
b1fc587a6d Make volume backup record commands available in v3
They work just fine in Volume API v3 but they were limited in OSC
to v2.

Change-Id: I510383f8e0cbf05ec24caa1cad330f12f82a913d
Story: 2007896
Task: 40279
2020-07-05 09:55:49 +02:00
Zuul
1d8781a369 Merge "Remove enabling of glance v1 API" 2020-07-04 18:18:36 +00:00
Zuul
03b6f53675 Merge "Remove translation sections from setup.cfg" 2020-07-04 16:46:55 +00:00
Ghanshyam Mann
4638dbc7f3 Remove enabling of glance v1 API
devstack removing the glance v1 api enable
option[1] because there is no v1 entry point in glance
now[2].

Let's remove ths GLANCE_V1_ENABLED variable setting from
zuul job too to avoid any confusion of glance v1 is still
available.
[1] https://review.opendev.org/#/c/698808/
[2] https://review.opendev.org/#/c/532503/

Change-Id: I6d3a38eee0c75bbc795bad732fe547181d15c677
2020-07-03 10:06:12 -05:00
Monty Taylor
c04ec16cf7 Expose flag for forcing use of import for images
openstacksdk added support for using image import as a fallback
which is transparently supported here, but also provides an
override flag to allow a user to force use of import. Expose that
here.

Depends-On: https://review.opendev.org/737608
Change-Id: Ied938a8f63f305305a20ace42e9f4c84b0a5c00e
2020-06-30 07:02:23 -05:00
Zuul
d3691b81c6 Merge "Allow os quota list query to filter by project" 2020-06-29 22:22:25 +00:00
Zuul
abfca138d9 Merge "port: add --host to list command" 2020-06-26 01:13:35 +00:00
melissaml
ff2a70c418 Remove translation sections from setup.cfg
These translation sections are not needed anymore, Babel can
generate translation files without them.

Change-Id: Ic5d57186766257e9d37b3588e71f973cddad9be4
2020-06-23 12:22:58 +08:00
Mohammed Naser
307d23bb58 port: add --host to list command
This adds an option to allow filtering ports bound to a specific host
when listing them.

Change-Id: I747ed0f8b070074c51789576a158345f670fe733
2020-06-17 16:33:34 +00:00
Jens Harbott
8b7a2c8d59 Don't display Munch objects in the output
When the sdk gives us a resource that contains Munch columns, drop them
from the output as they are for programmatic usage only and have no use
in a CLI context.

Change-Id: Idd7306cd763b5a017a66e410e70e1adb02663c2a
2020-06-17 10:09:36 +00:00
Jens Harbott (frickler)
a04172969a Revert "Format location columns in network commands"
This reverts commit 6ee7b8d138e07bfc37c5cd887f7afa49cdabb02f.

Change-Id: I5f59959ba8a01aba49e29f4cb007397467344e58
2020-06-17 10:09:36 +00:00
Zuul
3e6874dc87 Merge "Remove os-client-config references" 2020-06-11 15:44:42 +00:00
Gabriel Ramirez
176907f70e Allow openstack flavor set to update flavor description using name
Modified take_action() method for SetFlavor to use
flavor id instead of flavor name when setting description

Closes-Bug: #1844708 
Story: #2007781
Task: #40019

Change-Id: If6798c89fef4c9feb4ebb460722b891f5655037d
2020-06-10 22:49:44 +00:00
Zuul
7f08bf7577 Merge "image: autogenerate docs" 2020-06-09 02:10:31 +00:00
Zuul
09970d48e0 Merge "identity: autogenerate docs" 2020-06-09 02:10:29 +00:00
Zuul
f6810edf41 Merge "Add cliff to libs-from-git for devstack functional tips" 2020-06-09 02:10:28 +00:00
Zuul
831dd3fe12 Merge "Make container list --all work" 2020-06-09 00:21:52 +00:00
Zuul
730a8505f6 Merge "Add OpenStack Client for Manila docs" 2020-06-08 23:17:53 +00:00
Eric Fried
da3c3bde24 image: autogenerate docs
$namespace = openstack.image.v{1|2}

The subcommand documents for $namespace were hardcoded and thus prone to
drift over time. This commit removes the hardcoded content and uses the
autoprogram-cliff directive to generate them automatically from the
subcommand configuration classes.

Some reorganization happened here. The `image` subcommand name is shared
by image v1 and v2. Previously the hardcoded document had them combined
and interleaved. Attempting to preserve this with autoprogram-cliff
would have required significant additional infrastructure. However,
since most readers care completely about one and not at all about the
other, we instead split the v1 and v2 versions of these commands into
separate pages. In case links to the old pages exist in the wild, they
are preserved, but moved (with redirects) to a hidden directory, and
populated simply with links to the new version-specific generated
documents.

Change-Id: I24dc6dc10671c7f1267c27002542f61f8a3c18ae
2020-06-08 16:34:28 -05:00
Eric Fried
26878e7d53 identity: autogenerate docs
$namespace = openstack.identity.v{2|3}

The subcommand documents for $namespace were hardcoded and thus prone to
drift over time. This commit removes the hardcoded content and uses the
autoprogram-cliff directive to generate them automatically from the
subcommand configuration classes.

Special things:

- Some reorganization happened here. Certain subcommand names, such as
  `endpoint` and `project`, are shared by identify v2 and v3. Previously
  the hardcoded documents had them combined and interleaved. Attempting
  to preserve this with autoprogram-cliff would have required
  significant additional infrastructure. However, since most readers
  care completely about one and not at all about the other, we instead
  split the v2 and v3 versions of these commands into separate pages. In
  case links to the old pages exist in the wild, they are preserved, but
  moved (with redirects) to a hidden directory, and populated simply
  with links to the new version-specific generated documents.

- The `federation domain` and `federation project` subcommands were
  previously absent from the docs. They are added. These are such small
  commands and they seem related, so they're put into a single document.

- Some pages were already being generated but were listing operations
  individually instead of using wildcards (possibly because they were
  created before wildcarding was supported by cliff). These are changed
  to use wildcarding. (We want to do this wherever possible as it is
  more future-proof in the event that more operations are added to a
  subcommand later.)

- The `service provider` document was incorrectly titled `identity
  provider`. Fixed.

Change-Id: I2030f9fe370038c5908b6eb6bed9692a73fe5067
2020-06-08 16:34:27 -05:00
Monty Taylor
7696593dc1 Remove os-client-config references
We've depended on openstacksdk for config for ages now, clean up
after ourselves and stop installing it in tests.

Change-Id: I66b3ec2a36bc462d2f1ac151e95ccbdc946076b8
2020-06-08 16:20:28 -05:00
Monty Taylor
2cb4193579 Add cliff to libs-from-git for devstack functional tips
We should also use cliff from git in the tips jobs so that we can
see whether changes there break things.

Change-Id: Ie3375eb7bafafef7fa8209aa6500d1254e29954e
2020-06-08 21:18:06 +00:00
Maari Tamm
aa7b84fd08 Add OpenStack Client for Manila docs
This commit includes documentation about OSC
implementation for Manila.

bp openstack-client-support

Change-Id: Ic91a81e16e506103c08ef42ed0f8634a2b70e1dd
2020-06-06 15:48:10 +00:00
Zuul
00e88822e3 Merge "Replace assertItemsEqual with assertCountEqual" 2020-06-05 19:32:08 +00:00
Zuul
57c02953ac Merge "Switch to newer openstackdocstheme and reno versions" 2020-06-05 18:32:11 +00:00
Zuul
897c6a2df3 Merge "Remove congress" 2020-06-05 16:16:38 +00:00