Commit Graph

49 Commits (30d5f14a700dd53d80e0fbedefd9b1ad337390f9)

Author SHA1 Message Date
Artem Goncharov 0f4f42b652 Switch compute flavors from novaclient/direct to SDK
Let's switch flavors from novaclient or direct API requests onto using
SDK. Microversion agreement comes out of the box.

SDK normalizes property names, while OSC uses server side names. In
order not to break OSC users continue using server-side names.

Change-Id: I62b2ed8488ee4ac9c42051311bcfb455506ddd90
3 years ago
Rodolfo Alonso Hernandez 8387b114e3 Add "fields" parameter to ListPort query
This new query parameter will allow to send a query to the Neutron
server filtering only by those parameters needed by the list
command: ID, name, MAC address, fixed IPs and status.

When using input parameter "long", security groups IDs, device owner
and tags will be added to the fields filter.

With 4500 ports, those are the execution times for the command
"openstack port list" (average values in a development environment):

                 Neutron API (seconds)  CLI (seconds)
Without filter:  3.05                   10.15
With filter:     2.76                   8.19


Change-Id: I1cccf0bc3533f8085e8dd61bf2fbe78c49b74b31
Closes-Bug: #1897100
3 years ago
Zuul 7146deef00 Merge "update lower-constraints.txt" 3 years ago
likui 9b02f37e8f update lower-constraints.txt
We also need to change the lower-constraint requirements to make them
py3.8 compatible. See


Change-Id: I04a0fcd98327b9f41e24e19bcab97c813760f414
3 years ago
Artem Goncharov e05d39abb5 Switch console url show operations to SDK
Switch from using novaclient to SDK for openstack console url show operation.

Change-Id: Ibe247825148788c549c2c1e991aae92338cdf557
3 years ago
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
3 years ago
songwenping c2df9215e1 Remove usage of six
With python3.x, classes can use 'metaclass=' instead of
'six.add_metaclass', 'six.iteritems' and 'six.iterkeys' can
be replaced by 'items' and 'keys', 'six.moves.urllib.parse'
can be replaced by 'urllib.parse', 'six.StringIO' and
'six.moves.cStringIO' can be replaced by 'io.StringIO',
'six.text_type' and 'six.string_type' are just 'str'.

Change-Id: I84848c0bf8ab3c36dd821141191e2725e4e3b58b
3 years ago
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
3 years ago
Zuul 9fb68eca44 Merge "Expose flag for forcing use of import for images" 3 years ago
Zuul 42692264f7 Merge "switch to stevedore for entry points" 3 years ago
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 <>
3 years ago
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

Change-Id: Ied938a8f63f305305a20ace42e9f4c84b0a5c00e
3 years ago
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
3 years ago
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
3 years ago
Andreas Jaeger b5389dab02 Remove congress
Congress and python-congressclient have been retired and also
removed from global requirements, thus requirements-check job fails.

Remove congress from this repo.

Change-Id: Ibf68fee49e69264a1c46b2f456901d2620befe3c
3 years ago
Zuul 4886b02380 Merge "Use unittest.mock instead of third party mock" 3 years ago
Zuul 347c5b9df4 Merge "Add 'address_scope' type support to network rbac commands" 3 years ago
Sean McGinnis 725e004d32
Use unittest.mock instead of third party mock
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.

Change-Id: Ibd39328c27b68190e2edbf1f52fcea52db3ae791
Signed-off-by: Sean McGinnis <>
3 years ago
pedro 74a7c1d9d6 Add description field to portforwarding NAT rules
Add the `description` field to Floating IP Port Forwardings

Change-Id: I6477368e32570c96cacddba4f86455262e533277
Implements: blueprint portforwarding-description
Closes-Bug: #1850818
3 years ago
Bence Romsics dba57c85d5 Add command: router add/remove route --route
Add commands to osc to call the two new API methods introduced by
new Neutron extension: extraroute-atomic.

Bump our openstacksdk requirement to >=0.38.0 which contains
the corresponding sdk change.

The lower-constraints of dogpile.cache and keystoneauth1 are bumped
because of requirements bumps in openstacksdk.

The lower-constraint of decorator is bumped because of problem already
fixed by amotoki here:

Change-Id: Ia9b9c216f1d1161ebedac31594a2c464d77f4ae2
Partial-Bug: #1826396 (rfe)
Related-Change: (spec)
3 years ago
Igor Malinovskiy f03cb68ad8 Add 'address_scope' type support to network rbac commands
Change-Id: I6a4b7219934805c1bbd1e88fcc670ae231d9ac37
Partial-Bug: #1862968
3 years ago
Zuul 21c883b3d3 Merge "Switch image to use SDK" 3 years ago
Artem Goncharov 60e7c51df4 Switch image to use SDK
This is a work to switch OSC from using glanceclient to OpenStackSDK.

With this change only v2 is using OpenStackSDK. V1 is still using
glanceclient and will be switched in a separate change.

Remove the direct depend on keystoneauth- let that flow through

Change-Id: I36f292fb70c98f6e558f58be55d533d979c47ca7
3 years ago
Bence Romsics aac4f8c4f1 Bump lower constraint of MarkupSafe
setuptools 46.0.0's drop of the Features feature broke
python-openstackclient's lower-constraints job on master
via the MarkupSafe package. Bump the lower constraint of
MarkupSafe to fix lower-constraints on master.

Change-Id: Ib0a6f94a6611b221efbf76f6f25b55c43782546f
3 years ago
Daniel Bengtsson bf2beb9e86 Stop configuring install_command in tox and stop use pip.
Currently, we are overriding 'install_command' to use 'pip'. This is
considered poor behavior and 'python -m pip' should be used instead:

It turns out that this is the the default value provided by tox:

So we can remove the line and simply use the default value. Use the
right way when it's necessary.

Change-Id: I410173d5fdcd8c592d98eed2f48b98e06299e8b3
3 years ago
Colleen Murphy 70ab3f9dd5 Add support for app cred access rules
This commit introduces the --access-rules option for 'application
credential create' as well as new 'access rule' commands for listing,
showing, and deleting access rules.

bp whitelist-extension-for-app-creds

Change-Id: I04834b2874ec2a70da456a380b5bef03a392effa
3 years ago
Michael Johnson db29e28b7c Switch to using osc_lib.utils.tags
This patch updates the network modules to use the new
osc_lib.utils.tags module and removes the in tree version.

A previous patch[1] moves the code to osc-lib to allow other
projects to leverage the code.


Change-Id: Id0c34029e327de50c5fd2732bae5fbf45bbd16ee
3 years ago
Sean McGinnis 90ca67bdae
Raise hacking to more recent 2.0.0
Change-Id: I3cf36ed4d8fb5d003acae762820a8d80f75a11e9
Signed-off-by: Sean McGinnis <>
3 years ago
zhangbailin 874a726f52 Microversion 2.79: Add delete_on_termination to volume-attach API
Added ``--disable-delete-on-termination`` and
``--enable-delete-on-termination`` options to the
``openstack server add volume`` command that enables users to mark
whether to delete the attached volume when the server is destroyed.


Part of blueprint support-delete-on-termination-in-server-attach-volume

Change-Id: I6b5cd54b82a1135335a71b9768a1a2c2012f755b
4 years ago
Eric Fried 977b0c8591 Use autoprogram-cliff for remaining plugin docs
Sphinx errors have been fixed in the plugin projects for octavia, rsd,
trove, watcher, and zun, so we can now use autoprogram-cliff to generate
the docs for those.

Change-Id: Ia7790c5e86957afd0aec8f9a04ffc7aa968b4eeb
Story: #1735016
Task: #37241
4 years ago
Eric Fried 67a5654d49 Add plugin doc page for watcher
This was being omitted because whenever the plugin page was produced,
python-watcherclient wasn't in global-requirements. It is now, so
include a page for it in the plugin docs.

NOTE: We would like to use autoprogram-cliff to make the documentation
complete, but that breaks the build. For now, this is better than

Change-Id: I49822242b9a0c031a053d6c2fd9f644a585f4ba5
4 years ago
Eric Fried 8cdc7348d1 Add placement to known plugins
Add the osc-placement project (osc plugin for the placement service) to
the list of known plugins.

Change-Id: I77b614b38ecf872d0d93473b834994913930b76f
4 years ago
zhangbailin fcd46acb69 Microversion 2.77: Support Specifying AZ to unshelve
This patch adds a new parameter ``--availability-zone`` to
``openstack server unshelve`` command. This can help users to specify
an ``availability_zone`` to unshelve a shelve offloaded server from
2.77 microversion.


Implements: blueprint support-specifying-az-when-restore-shelved-server

Change-Id: Ia431e27c2a17fe16466707cc362532860ecf22df
4 years ago
Hongbin Lu 7549d260aa Bump lower constraint of python-zunclient
Projects that depends on python-zunclient should use the latest
version as lower constraint.

Change-Id: Idc865788f35427cc0f2926b31089ec4097831334
4 years ago
Dean Troyer a88e95873e Bump min osc-lib to 1.14.0
This is required for osc4 and the movement of functions out of OSC.

Change-Id: I690954b6dccb11dd1a4f512b6777d645de5191f9
Signed-off-by: Dean Troyer <>
4 years ago
Stephen Finucane 6419533f43 Bump hacking version
Pick up newer versions of this library. Thankfully no serious changes
are needed.

Change-Id: I69e523844529fc1c8aa0c1ce764182dbe29cfeb6
Signed-off-by: Stephen Finucane <>
4 years ago
zhu.boxiang 340f25fa14 Add host and hypervisor_hostname to create servers
Adds the --host and --hypervisor-hostname options to
``openstack server create`` CLI.


Change-Id: If188c3d96fa506dbe62ef256418f2f9bca1520c2
Blueprint: add-host-and-hypervisor-hostname-flag-to-create-server
4 years ago
Surya Seetharaman 187be0ac22 Microversion 2.73: Support adding the reason behind a server lock
This patch adds a new parameter ``--reason`` to ``openstack server lock``
command and ``--locked``, ``unlocked`` filtering parameters to
``openstack server list`` command. This can help users to provide a
reason when locking the server and to filter instances based on their
locked value from 2.73 microversion.

Implements blueprint add-locked-reason

Change-Id: Ib2714f98b24d47e570da8a6c231e765acd2ff595
4 years ago
Zuul 1894a3cb17 Merge "Add --key-name and --key-unset option for server rebuild API." 5 years ago
Monty Taylor dfd37a2e6e
Make use of keystoneauth service-type filtering for versions
The first version of the versions show command does client-side
service-type filtering, which while functional, causes many more API
calls than needed. Now that keystoneauth supports the filtering at the
source, use it.

Change-Id: I57c49e67f9cb285a5f5bc19ec53a42d10de9f0da
5 years ago
Fan Zhang f82c5b85ce Add --key-name and --key-unset option for server rebuild API.
Change-Id: I6d4793a8e961080ea1d6d414cef8d6bbed0c53e7
Story: 2002609
Task: 22228
Signed-off-by: Fan Zhang <>
5 years ago
Josephine Seifert 1981eb2250 osc-included image signing (using openstacksdk)
This extension adds image signing functionality to the "image create" command.
Therefore, new CLI options --sign-key-path and --sign-cert-id have been added.
This patch uses openstacksdk as the signing backend library instead of cursive.
Therefore, requirements and lower_constraints have been updated to use the
openstacksdk version 0.17 or higher.

Depends-On: Idc15b9a12d408bd4b2e096da8402c374be56f9fa
Change-Id: Ia20bc02a49c3fbeb9222e485e3396395f4ab817a
Story: 2002128
Co-Authored-By: Markus Hentsch <>
5 years ago
Zuul d177727a6e Merge "Implement support for registered limits" 5 years ago
Jake Yip b90b93e143 Fix error with image show when image name is None
Need to bump osc-lib to 1.10.0

Closes-Bug: #1736696
Depends-On: I2aab5cc1f550848bda2b90ef7ef9a60f07b88996
Change-Id: I7420204f28d36529354e5671bd88587d9b15bb06
5 years ago
Lance Bragstad 641a4faac1 Implement support for registered limits
This commit adds support for users to manage registered limits via
the command line.

bp unified-limits

Change-Id: Id8377363f7a3248b45aeeba21d2acc02684a0305
5 years ago
Tuan Do Anh 70031687f9 Fix lower-constraints.txt
During the change
neutron-vpnaas lower-constraints.txt looks out-of-date.
This commit fixes lower-constraints.txt.

Change-Id: Id9cfb463a98bdcc3c45505d8701c515549ecaa55
5 years ago
Lance Bragstad 8bfa180430 Add system role functionality
This commit adds the necessary bits to expose system role
assignments to openstackclient via python-keystoneclient.

bp system-scope

Depends-On: Iecbcbf020a15f2bec777334c648d4477f89f3b2c
Change-Id: I261e84700b51e8715eaebdc3f8f8bc46b68542c2
5 years ago
Jens Harbott 47d0d0e0c0 Fix lower-constraints.txt
This was originally generated before the compliance test was installed,
so it is now failing for every unrelated change to requirements.

Replace lower-constraints.txt with the output of running
openstack/requirements/tools/ .

Change-Id: I492e663622db75994bdababfa6dc81589e3fb53b
5 years ago
Doug Hellmann bf32cdf3a9 add lower-constraints job
Create a tox environment for running the unit tests against the lower
bounds of the dependencies.

Create a lower-constraints.txt to be used to enforce the lower bounds
in those tests.

Add openstack-tox-lower-constraints job to the zuul configuration.

for more details.

Change-Id: I4a4ca9726fab1d0cf9a33311201b7f65951a0942
Signed-off-by: Doug Hellmann <>
5 years ago