summaryrefslogtreecommitdiff
path: root/glanceclient/v2
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Add support for glance-download import method"4.1.0Zuul2022-08-302-6/+66
|\
| * Add support for glance-download import methodPranali Deore2022-08-302-6/+66
| | | | | | | | | | Implements: blueprint glance-download-import-support Change-Id: Ia2bfad82bccf9acb6103b21112e680c44e295d39
* | Bump default pagesizeErno Kuvaja2022-08-261-1/+1
|/ | | | | | | | | | | | Bumping default pagesize to 200. With the previous default value of 20 glanceclient was doing lots of extra requests and schema validations. Based on my tests no performance improvement was seen over the pagesize of 200. Change-Id: I6d740ca3a9b32bf5d064d3ea74273bb619b32ad4 Closes-Bug: #1987834
* Check if stdin has isatty attributeBenedikt Loeffler2022-07-071-2/+2
| | | | | | | When the stdin is closed, it has no isatty atrribute which leads to a KeyError. Closes-Bug: #1980890 Change-Id: If9a3bf68b8dfd953b346697241166578d18bb563
* Add support for Cache APIErno Kuvaja2022-02-223-0/+137
| | | | | | | This change provides support for the Cache API changes and deprecation path for glance-cache-manage command. Change-Id: I6fca9bbe6bc0bd9b14d8dba685405838131160af
* Merge "Add an optional parameter --append"Zuul2022-02-172-6/+11
|\
| * Add an optional parameter --appendMridula Joshi2022-02-162-6/+11
| | | | | | | | | | | | | | | | | | | | | | This patch will add an optional parameter --append to the glanceclient command md-tag-create-multiple to provide the facility of appending the tags. If the parameter is present it will append the tags to existing one, else it will overwrite the existing tags. Depends-On: https://review.opendev.org/c/openstack/glance/+/804966 Change-Id: I1841e7146da76b13f4cd8925e19f59d0eaf08f7a
* | Merge "Add an optional parameter --detail"Zuul2022-02-162-2/+13
|\ \
| * | Add an optional parameter --detailMridula Joshi2022-02-022-2/+13
| |/ | | | | | | | | | | | | | | | | This patch appends th --detail parameter to the ``stores-info`` command. With sufficient permissions, display additional information about the stores. Depends-On: https://review.opendev.org/c/openstack/glance/+/824438 Change-Id: I6ae08ab3eaab0c2b118aa7607246214b28025dfe
* | Add support for usage APIDan Smith2022-01-313-0/+35
|/ | | | | | | | This is really a very simple activity of fetching and showing the results of the usage API in table form for the user. Depends-On: https://review.opendev.org/c/openstack/glance/+/794860 Change-Id: I3d9360785a759e4a6e7905710400baea80776052
* Add member-get commandMridula Joshi2021-08-022-1/+15
| | | | | | | | | It is observed that python-glanceclient was missing support for GET /v2/image/{image_id}/member/{member_id} API. This patch adds new command `member-get` to support this missing operation. Closes-Bug: #1938154 Change-Id: I3709f6a39535aa45bee70f468f015ac60a1375a8
* Get tasks associated with imageAbhishek Kekane2021-03-022-0/+37
| | | | | | | Add support to get tasks associated with specific image. bp: messages-api Change-Id: Ia505cf6f47ca6c628e195be3ca5231d22d53040d
* Fixes "stores" property added to the image3.2.1Erno Kuvaja2020-07-301-0/+3
| | | | | | | | "stores" property gets added to the image when `glance image-create-via-import` is called with --stores Change-Id: I514e6e3ac2f3a1f56fb7883ed403a04b1e7f13b0 Closes-Bug: #1889666
* Do not use the six library.Cyril Roelandt2020-06-233-16/+15
| | | | Change-Id: I3dbfcfa0f5f590a41ed549afd44537d8ed41433a
* Fail gracefully when MD5 is unavailableBrian Rosmaita2020-05-041-2/+4
| | | | | | | | | The glanceclient currently assumes that MD5 will always be available. This is not the case, however, in a FIPS-compliant environment. This patch enables the glanceclient to fail gracefully in such a case. Closes-bug: #1871675 Change-Id: Ibd89989e06cc5be7da71f5f21561d73b5abc4104
* Pass --all-stores, --allow-failure as bool to APIAbhishek Kekane2020-04-081-3/+3
| | | | | | | | | | | Newly added command line options --all-stores, --allow-failure are boolean but we are passing it as a string to glance API. This will cause problem if those parameters are not converted to boolean at API side. Passing these parameters as boolean instead of string to API. Change-Id: I8d4eab9241fc9bb24bc40b47bf18d63c86a97d77 Closes-Bug: #1871674
* Update hacking for Python3Andreas Jaeger2020-04-021-9/+9
| | | | | | | | | | | | The repo is Python 3 now, so update hacking to version 3.0 which supports Python 3. Fix problems found. Remove hacking and friends from lower-constraints, they are not needed for installation. Change-Id: I5ae47a7b11ff29a301e440c15daf30db7738485b
* Merge "update doc url to new"Zuul2020-03-261-2/+2
|\
| * update doc url to newlvxianguo2018-08-161-2/+2
| | | | | | | | Change-Id: I35e03b74f7ef79a0997dfd931f29b20350537189
* | Delete image from specific storeErno Kuvaja2020-03-202-0/+26
| | | | | | | | | | | | | | Add support to delete image from specific store. bp: delete-from-store Change-Id: Ie57d7de5822264a5ea8a5f4587ab8cfb4afb79de
* | Add support for copy-image import method3.0.0Abhishek Kekane2020-02-271-0/+12
| | | | | | | | | | | | | | | | This change adds support for copy-image import method which will copy existing images into multiple stores. Change-Id: I748a8fb3dbaf9c2e4d887a2ecd4325e27a8429c4 bp: copy-image-multiple-stores
* | Add support for multi-store importErno Kuvaja2020-02-272-8/+105
| | | | | | | | | | | | | | | | | | | | | | This change adds support for providing multiple target stores where image can be imported. Co-authored-by: Erno Kuvaja <jokke@usr.fi> Co-authored-by: Abhishek Kekane <akekane@redhat.com> bp: import-multi-stores Change-Id: I8730364263f1afd5d11fd56939851bda73a892bb
* | Merge "Rename --backend to --store"2.17.0Zuul2019-09-131-21/+21
|\ \
| * | Rename --backend to --storeAbhishek Kekane2019-05-141-21/+21
| | | | | | | | | | | | | | | | | | | | | | | | As a part of vocabulary correction renamed --backend parameter to --store. Modfied corresponding tests as well. bp:multi-store-vocabulary-correction Change-Id: I3dc115f5f0f3c4edcca0209e139aa3d1d816357c
* | | Correcting typo in shell.py - enviroment to environment.root2019-07-301-1/+1
|/ / | | | | | | | | | | | | There is a typographical error in glanceclient/v2/shell.py. Correcting spelling from enviroment to environment. Change-Id: Ia19a4417cd05d228adc26f9d7c82f4aa3c24488c
* | Merge "Embed validation data when adding location"Zuul2019-03-072-2/+19
|\ \
| * | Embed validation data when adding locationimacdonn2018-10-242-2/+19
| |/ | | | | | | | | | | | | | | Add support for embedding of checksum, os_hash_algo and os_hash_value when adding a location to an image. Depends-On: https://review.openstack.org/597648 Change-Id: Ibbe2f2bb226f52cc6b2ab591913b1797d2b086c0
* | Add image-list filter for multihashBrian Rosmaita2019-01-171-1/+4
| | | | | | | | | | | | | | | | | | | | | | This was missed when multihash support was added to the glanceclient. The os_hash_value is an indexed field in the API. Includes a release note. Closes-bug: #1788271 Change-Id: Ibfe28b8c644967b7e0295dfd3f55c3ae1b0cbb2d
* | Show the backend store infoLiang Fang2018-11-081-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When running "glance -v image-list" there's no store info listed, so user cannot know the type of the backend. This patch added an new option "--include-stores" and is to add the store id to the output of "glance image-list --include-stores". The final output may like: +-----+------+-------------+-----+----------+--------+-----+------+ | ID | Name | Disk_format | ... | Size | Status |Owner|Stores| +-----+------+-------------+-----+----------+--------+-----+------+ | xxx | img1 | raw | ... | 10737418 | active | xxx | ceph | | xxx | img2 | raw | ... | 5086345 | active | xxx | file | +-----+------+-------------+-----+----------+--------+-----+------+ Change-Id: If86ef714c3aa03ce43ef29f26892f431f4766560 Co-authored-by: Jack Ding <jack.ding@windriver.com> Signed-off-by: Liang Fang <liang.a.fang@intel.com>
* | Use "multihash" for data download validationBrian Rosmaita2018-09-072-7/+70
|/ | | | | | | | | | | | When the Glance "multihash" is available on an image, the glanceclient should use it instead of MD5 to validate data downloads. For cases in which the multihash specifies an algorithm not available to the client, an option is added to the image-download command that will allow fallback to the legacy MD5 checksum verification. Change-Id: I4ee6e5071eca08d3bbedceda2acc170e7ed21a6b Closes-bug: #1788323
* Add support for hide old imagesAbhishek Kekane2018-07-252-7/+48
| | | | | | | | Added --hidden argument to list, create and update call. Related to blueprint hidden-images Change-Id: I1f2dcaa545c9da883186b20a96a70c7df994b994
* Merge "Add multi-store support"Zuul2018-07-252-7/+107
|\
| * Add multi-store supportAbhishek Kekane2018-07-242-7/+107
| | | | | | | | | | | | | | | | | | | | | | | | Added multi-store support. User can now use '--backend' option to pass desired store while creating, uploading or importing image to speific store backend. Added new command 'stores-info' which will return available stores information to the user. Related to blueprint multi-store Change-Id: I7370094fc4ed47205b5a86a18b22aaa7b9457e5b
* | Merge "Add support for multihash"Zuul2018-07-242-3/+19
|\ \
| * | Add support for multihashAbhishek Kekane2018-07-232-3/+19
| |/ | | | | | | | | | | Related to blueprint multihash Change-Id: Iff4a5fe224b5d47255d7f23f65bbc08468f47f02
* | image-list: add checksum algorithm descriptionChen Hanxiao2018-07-241-1/+1
|/ | | | | | | | We use MD5 for checksum, add this description in cli helps. Change-Id: I3469b0dface63f4684ad39421eee4c2a2de4d80b Signed-off-by: Chen Hanxiao <chenhx@certusnet.com.cn>
* Replace 'raise StopIteration' with 'return'Dougal Matthews2018-06-291-1/+1
| | | | | | | | | | With PEP 479, the behaviour of StopIteration is changing. Raising it to stop a generator is considered incorrect and from Python 3.7 this will cause a RuntimeError. The PEP recommends using the return statement. More details: https://www.python.org/dev/peps/pep-0479/#examples-of-breakage Change-Id: Ia067940066a5666926dcf61136b03d721a87666e
* Merge "Update local copy of image schema for 2.6"Zuul2018-04-111-1/+2
|\
| * Update local copy of image schema for 2.6Brian Rosmaita2018-04-081-1/+2
| | | | | | | | | | | | | | | | Update the local copy of the image schema to reflect Image API 2.6. Change-Id: Ib0e56027927880d0fa198ffd8ea4b57e39f9d0fe Closes-bug: #1762044 Depends-on: https://review.openstack.org/#/c/559501/
* | Make image-import fail fasterBrian Rosmaita2018-04-041-10/+44
|/ | | | | | | | Add checks to image-import command so that it provides better user feedback in failure situations. Change-Id: I8b6b32c3d1d1a745aa68ff8dc629419dff9bb130 Closes-bug: #1758718
* Make image-create-via-import fail fasterBrian Rosmaita2018-04-041-20/+70
| | | | | | | | | | | | | | Add checks to the image-create-via-import commmand so that it provides better user feedback and doesn't begin the import workflow unless the input has a chance of succeeding. Preserves backward compatibility with the current image-create command by (1) allowing an image record only to be created when no import-method is specified AND no data is supplied, and (2) doing the glance-direct workflow when no import- method is specified AND data is provided. Also adds the ability for the import-method to be set as an env var OS_IMAGE_IMPORT_METHOD. Change-Id: I0a225f5471a9311217b5d90ebb5fd415c369129a Closes-bug: #1758149
* Merge "Update properties URL"Zuul2018-03-221-1/+1
|\
| * Update properties URLBrian Rosmaita2018-03-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | Help text for some image properties (architecture, os_distro) is pulled from the glanceclient's local version of the image schema. The URL for those property definitions has gotten out of sync with Glance. This patch updates the URL to be the same as that given in the Glance image-schema response. Change-Id: I4e46e78525fe5c00e031a98c47cacc17e5693d53 Closes-bug: #1757918
* | Check for container,disk_format on web-downloadBrian Rosmaita2018-03-221-1/+1
|/ | | | | | | | | Fail image-create-via-import requests for the web-download import method that don't include values for container_format or disk_format. Closes-bug: #1757927 Change-Id: Ic5c81916823ff32f2dbddd32b40e825de0697dc9
* Add support for web-download import methodPranaliD2018-03-212-6/+28
| | | | | | | | | | | | | This change adds support for 'web-download' import method to 'image-import' and 'create-image-via-import' call. To use this 'web-download' import method, user needs to pass --uri option 'a valid uri to external image to import in glance' to 'image-import' and 'create-image-via-imaport' calls. Co-authored-by: Pranali Deore <pdeore@redhat.com> Co-authored-by: Erno Kuvaja <jokke@usr.fi> Change-Id: I0e1d18844f64723608288de473e97710798eb602
* Compare against 'RequestIdProxy.wrapped'Stephen Finucane2018-01-021-1/+1
| | | | | | | | | | | | Due to the 'glanceclient.common.utils.add_req_id_to_object' decorator, an instance of 'glanceclient.common.utils.RequestIdProxy' is returned for most calls in glanceclient. If we wish to compare to None, we have to compare the contents of this wrapper and not the wrapper itself. Unit tests are updated to highlight this. Change-Id: I7dadf32d37ac2bda33a92c71d5882e9f23e38a82 Closes-Bug: #1736759
* Merge "image-create-via-import fails with ValueError"Jenkins2017-08-241-1/+4
|\
| * image-create-via-import fails with ValueErrorAbhishek Kekane2017-08-241-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | CLI image-create-via-import fails with ValueError. The reason is create command returns RequestIdWrapper object and not image and response. Further it fails with AttributeError: 'Namespace' object has no attribute 'import_method'. The reason is do_import_image() call requires 'import_method' as input which is not provided at the moment. Change-Id: Ic4c4d1f3c5d290b584840e8f9047fb53611a5748 Closes-bug: #1711511
* | Merge "Fix image-import call"Jenkins2017-08-241-1/+1
|\ \ | |/ |/|
| * Fix image-import callBrian Rosmaita2017-08-181-1/+1
| | | | | | | | | | | | | | | | | | Change the request body sent from the client to be the format that the API expects for the image-import call. Depends-On: I08783e28719e63b5a4b2115b8fce135e55be460a Change-Id: I5e34d772d561306c6f103c859740658a825dd189 Closes-bug: #1711259