6475 Commits

Author SHA1 Message Date
4c059bb2d8 Update reno for stable/rocky
Change-Id: I378fcc3ba26885102b817d606ca78c31a304ebe7
2018-08-10 03:04:38 +00:00
Erno Kuvaja
6884266251 Add prelude to Rocky releasenotes
Also removes the bullet point prelude that was in b3.

Change-Id: I3a5c71a93ab404f4a3bb236270706e97e0b12b0d
2018-08-09 20:51:36 +01:00
Zuul
3e187ac364 Merge "Add release note for multi-store feature" 2018-08-09 19:37:18 +00:00
Brian Rosmaita
8f3331e289 Add release note for multi-store feature
Change-Id: I55b3bea2d72610b1e55cc76b898621e610e80100
2018-08-09 10:26:24 -04:00
OpenStack Proposal Bot
8e441ac608 Imported Translations from Zanata
For more information about this automatic import see:
https://docs.openstack.org/i18n/latest/reviewing-translation-import.html

Change-Id: I6e2b3a270acc0e5a761e8a3f01d36e5a83ee4ef3
2018-08-09 07:36:04 +00:00
Brian Rosmaita
b6d5100de7 api-ref: update version history
Update version history to include the Rocky changes.

Change-Id: Ie673a52c72a5975ac059002c351782a1c6d8df90
2018-08-08 16:15:41 -04:00
Zuul
8b1527e465 Merge "Sync Rocky example configs" 2018-08-08 20:03:57 +00:00
Zuul
671cfed406 Merge "Add API version 2.8" 2018-08-08 20:03:56 +00:00
Zuul
e4ecf7c0ea Merge "Document hw_cpu_policy and hw_cpu_thread_policy image properties" 2018-08-08 20:01:05 +00:00
Zuul
bfa25c5e5c Merge "Replace mox with mock" 2018-08-08 00:00:02 +00:00
Zuul
4f4dba220b Merge "api-ref: make the discovery section more general" 2018-08-07 23:16:26 +00:00
Zuul
e40f65ded1 Merge "Unit/Functional tests for multi store support" 2018-08-07 23:15:53 +00:00
Erno Kuvaja
208935af96 Add API version 2.8
This change bumps the API to EXPERIMENTAL 2.8 when multi back-end
is enabled.

Change-Id: Ie0e1ed84db1b227eea1774138b2a83172ff85bec
2018-08-07 16:39:06 +01:00
Brian Rosmaita
6187728bec api-ref: make the discovery section more general
Move all the v2/info calls to the same section of the api-ref.

Change-Id: I05cd7d89585a71cc8f5448cc3c08905da1638638
2018-08-07 11:31:37 -04:00
Erno Kuvaja
87a59ae52b Sync Rocky example configs
Change-Id: Ied1902018ded20b35bfa69200a1faee34fb3a4d6
2018-08-07 13:53:32 +01:00
zhangbailin
4a916d215b Replace mox with mock
Replace mox testing library by mock one in the file
glance/tests/unit/api/test_cmd.py

Change-Id: I2dde0ca59c4a80bd35c6c6b74c4d3231a97eaf74
partially-implements: blueprint replace-mox-with-mock
2018-08-07 14:22:44 +08:00
Brian Rosmaita
cacede14b4 Correct typo in help text
Fix the typo in the help text for the hasing_algorithm configuration
option introduced in Rocky for the multihash implementation.

Change-Id: I709631666895b4de49290178eaa5968ea0ae2e2f
2018-08-06 11:36:28 -04:00
Zuul
cbdd1ab222 Merge "Doc:Multiple stores support" 2018-08-06 14:07:09 +00:00
Abhishek Kekane
d6ac7460ca Doc:Multiple stores support
Added documentation and modified api-ref documents to
reflect multiple stores support changes.

Related to blueprint multi-store
Change-Id: I932297df8149968d31a5367a9ca71a5629045445
2018-08-03 11:17:59 +00:00
Zuul
b421f18a62 Merge "Add multi-store support" 2018-08-02 17:44:51 +00:00
Erno Kuvaja
8e16e41f4d Bump Imges API version to 2.7
This API version bump contains the extensions for hidden images
and multihash feature support.

Change-Id: I3d394b344492a1f06a4999a3f61cecf5ace30f23
2018-08-01 19:42:11 +01:00
Abhishek Kekane
73109de485 Unit/Functional tests for multi store support
Added some unit tests for coverage purpose.
Added functional tests for create and import scenarios.

Note:
For functional tests I have considered file store with two
different image directories.

Related to blueprint multi-store
Change-Id: I59e28ab822fb5f6940f48ddbf6dfba4cb7d4c509
2018-08-01 08:57:56 +00:00
Abhishek Kekane
cb45edf5c8 Add multi-store support
Made provision for multi-store support. Added new config option
'enabled_backends' which will be a comma separated Key:Value pair
of store identifier and store type.

DocImpact
Depends-On: https://review.openstack.org/573648
Implements: blueprint multi-store

Change-Id: I9cfa066bdce51619a78ce86a8b1f1f8d05e5bfb6
2018-08-01 08:53:47 +00:00
Brian Rosmaita
0b24dbd620 Multihash implementation for Glance
Partially implements blueprint multihash.

Requires glance_store 0.26.1

Co-authored-by: Scott McClymont <scott.mcclymont@verizonwireless.com>
Co-authored-by: Brian Rosmaita <rosmaita.fossdev@gmail.com>

Change-Id: Ib28ea1f6c431db6434dbab2a234018e82d5a6d1a
2018-07-31 21:28:38 -04:00
Matt Riedemann
d2a5c52680 Document hw_cpu_policy and hw_cpu_thread_policy image properties
These were found in the nova flavor extra specs docs [1] but not
the image properties docs, so they are added here.

[1] https://docs.openstack.org/nova/latest/user/flavors.html

Change-Id: I2225821f859d43b1458174b8b7baa05c50cd0cd7
Closes-Bug: #1784462
2018-07-30 15:26:07 -04:00
Zuul
ff77f59bd4 Merge "Remove Images API v1 entry points" 2018-07-27 06:08:31 +00:00
Abhishek Kekane
a308c44406 Hide old images
Added new boolean column "os_hidden" in images table. Images where
"os_hidden" = True will be omitted from the image list presented
to the user. This will apply to all image visibilities. However,
the images will continue to be discoverable. User can use
filter "os_hidden=true" in GET v2/images call to see all hidden
images.

Implements: blueprint hidden-images
Change-Id: If8f02ca94fdb8e1ac7a81853cd392988900172d1
2018-07-25 16:37:56 +00:00
Zuul
2f859cee90 Merge "Update glance documentation for trait support" 2018-07-17 07:38:57 +00:00
Lance Bragstad
3e47cbea34 Use glance.context.RequestContext in tests
There were some recent changes to oslo.policy that include specific
type checks of the ``creds`` parameter passed to the ``enforce()``
method:

  https://review.openstack.org/#/c/578995/

The above change allows consuming projects to pass instances
of oslo_context.context.RequestContext to the policy enforcer, as
opposed to building a dictionary instance from scratch multiple
different ways across projects.

The glance unit tests were failing with the new version of
oslo.policy (1.38.0) because they were passing in a Mock instance
which failed the new, more strict, type check.

This commit converts the setUp class of the tests to use an instance
of glance.context.RequestContext, which subclasses RequestContext
from oslo.context. It also sets the user_id and project_id attributes
of the context object to override authorization checks.

This should allow glance to pass with newer versions of oslo.policy.

Change-Id: I0a69bc9565d57fd6ad8484abc5fce0e8dd45f9f2
Closes-Bug: 1781976
2018-07-16 19:11:50 +00:00
Arvind Nadendla
b30ed486ae Update glance documentation for trait support
Required traits on the image allow specifying a server to be
built only on compute nodes which express those traits. The
Nova Scheduler has been updated to look at the image trait
properties when selecting compute nodes.

Updating the documentation for glance to explain the same.

Documentation is similar to flavor required traits documentation available
here: https://docs.openstack.org/nova/latest/user/flavors.html#extra-specs

Change-Id: I716821abf44238eecc9c4a1d198d8a31b87dedce
Implements: blueprint glance-image-traits
2018-07-13 11:09:37 -07:00
Erno Kuvaja
3dde3204d5 Remove Images API v1 entry points
This change removes option to configure Images API v1
This change removes Images API v1 endpoints from the router
This change removes all v1 tests
This change removes the v1 dependant glance-cache-manage command

This change does not remove all v1 codebase. Further cleanup and
decoupling will be needed.

Change-Id: Ia086230cc8c92f7b7dfd5b001923110d5bc55d4d
2018-07-13 10:21:49 +01:00
Doug Hellmann
f3496591ae fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: Ic9645685e0f9ae25b0b2b754b11e34d8aef41829
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-07-10 05:05:08 +00:00
Doug Hellmann
dd54b4881a replace cmp with total_ordering decorator
The cmp() built-in is no longer available under python 3 and the
__cmp__ method is not used. Remove __cmp__ and __ne__ and add a __lt__
method and use the functools.total_ordering decorator to provide all
of the rich comparison methods for StoreLocations.

Change-Id: Iae1d0c27bd82a42c80fc98f87c9b85edef527c51
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-07-09 12:52:20 +00:00
Zuul
4f16ddf347 Merge "Documentation for OSSN-0075 mitigation" 2018-07-06 20:59:49 +00:00
Brian Rosmaita
23d4e0e9c0 Documentation for OSSN-0075 mitigation
Updates the Glance Administration Guide and adds a release note.

Depends-on: https://review.openstack.org/#/c/579507/
Change-Id: I87343b67614da8dea3a09b10456f4bfc0042ed0e
2018-07-06 15:04:18 -04:00
Erno Kuvaja
864d1ad714 Change default age of purge_images_table to 180
The `glance manage purge-images-table` is supposed to be used
only if really required due to OSSN-0075. And the advice is
not to purge any freshly deleted rows due to the possible
ID collision of still in use images. This change increases
the default of "age_in_days" to 180 from it's original 30 to
stress this out. User can still define smaller age if they
must.

Change-Id: Idb13288b72b31940a357fc9b11db2d6bcd396261
2018-07-06 13:05:23 +01:00
Zuul
0a82f98084 Merge "Mitigate OSSN-0075" 2018-07-06 11:46:50 +00:00
Zuul
d01c004ccc Merge "Prevent taskflow creation in impossible import" 2018-07-05 16:32:14 +00:00
Abhishek Kekane
5cc9d99935 Mitigate OSSN-0075
Modified the current ``glance-manage db purge`` command to eliminate images
table from purging the records. Added new command
``glance-manage db purge_images_table`` to purge the records from images
table.

DocImpact
SecurityImpact

Change-Id: Ie6641659b54543ed9f96c393d664e52a26bfaf6a
Implements: blueprint mitigate-ossn-0075
2018-07-05 13:33:36 +00:00
Erno Kuvaja
0376185fb3 Prevent taskflow creation in impossible import
This change prevents taskflow creation during image import in cases
we know for sure that the image activation won't be successful.

The change follows the Glance principles of failing early and tries
to provide as meaningful error messages to the end user as possible.

Co-authored-by: Abhishek Kekane <akekane@redhat.com>
Closes-bug: 1758943
Change-Id: Iaee2781d07f4c0afd4f886f0b30b523bd47f1058
2018-07-02 13:53:21 +01:00
Kashyap Chamarthy
9a893e80c2 useful-image-properties.rst: Update default RNG source
Nova's libvirt driver has changed[*] the default source from /dev/random
to /dev/urandom:

    "Since libvirt 1.3.4, any RNG (Random Number Generator) device path
    (that returns random numbers when read!) is accepted. However, the
    recommended source of entropy is `/dev/urandom` (it is non-blocking;
    and doesn't have the same limitations of `dev/random`, which is a
    legacy interface)."

Update the relevant Glance documentation to reflect that.

[*] https://git.openstack.org/cgit/openstack/nova/commit/?id=814bfd93

Change-Id: I656b5c244b98202f3c8d019d0bbeddc4e7c0314a
Signed-off-by: Kashyap Chamarthy <kchamart@redhat.com>
2018-07-02 14:41:10 +02:00
Zuul
54329c6a21 Merge "Replace Chinese punctuation with English punctuation" 2018-06-20 17:22:14 +00:00
Zuul
83fd304ebe Merge "Refactor wait_for_scrubber_shutdown function" 2018-06-19 04:18:40 +00:00
Zuul
24e999932c Merge "Use group_regex to serialize scrubber tests" 2018-06-19 04:14:58 +00:00
Zuul
eb526faa72 Merge "Convert to string before using assertIn" 2018-06-19 04:14:57 +00:00
Zuul
e005e65833 Merge "Update Release CPL doc about periodic jobs" 2018-06-14 16:10:21 +00:00
Zuul
1b6f5998a0 Merge "Add image conversion plugin" 2018-06-12 06:30:38 +00:00
Erno Kuvaja
c6a663ea6d Add image conversion plugin
This change adds image conversion plugin for Interoperable
Image Import workflow.

Change-Id: Icd4f4f30b12f6dd073dcdbf7f842e933c75ae249
2018-06-11 21:23:50 +01:00
Zuul
5f89e04018 Merge "convert windows line endings to unix format" 2018-06-07 22:12:40 +00:00
Zuul
7d3ae1e9a6 Merge "Regenerate sample config files" 2018-06-07 20:15:45 +00:00