Commit Graph

100 Commits

Author SHA1 Message Date
Ghanshyam Mann d460333737 Update python classifier in setup.cfg
As per the current release tested runtime, we test
till python 3.11 so updating the same in python
classifier in setup.cfg

Change-Id: I703ff8cdebd2e929ab775f9b601a8542fb413153
2024-01-08 20:21:21 -08:00
Stephen Finucane f1823b5876 Remove 'egg_info' configuration
eggs are dead, long live wheels. We don't use this and it can be
confusing if one builds eggs since the version isn't taken from git
(using pbr) but rather from setuptools/distutils.

Change-Id: Iccfdb7fd0bd65318997c598db7e6cf59d4ac0df0
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2023-07-20 11:09:51 +01:00
Pierre-Samuel Le Stang 480ea3825f Implement glance-download internal plugin
Add a new import method called glance-download
that implements a glance to glance download in
a multi-region cloud with a federated Keystone.

This method will copy the image data and
selected metadata to the target glance, checking
that the downloaded size match the "size" image
attribute in the source glance.

Implements: blueprint glance-download-import
Co-Authored-By: Victor Coutellier <victor.coutellier@gmail.com>
Change-Id: Ic51c5fd87caf04d38aeaf758ad2d0e2f28098e4d
2022-08-23 08:26:52 -07:00
Ghanshyam Mann d55d250d33 Update python testing as per zed cycle teting runtime
In Zed cycle, we have dropped the python 3.6/3.7[1] testing
and its support. Moving the py36 job to py38 based as well as
updating the python classifier also to reflect the same.

openstack-tox-functional-py36-fips job is left which can be moved
to py38|py39 based once that job is defined in openatck-zuul-jobs
repo.

openstack-tox-functional-py36-fips job will be migrated to py38 or py39
in followup patch as that need openstack-zuul-config changes too.

[1] https://governance.openstack.org/tc/reference/runtimes/zed.html

Change-Id: Id0813d9dc553dd424732079039349b42f6f3201b
2022-05-19 12:56:56 -05:00
Zuul 21f9739b0d Merge "Add Python 3 only classifier" 2022-02-15 06:52:45 +00:00
Takashi Kajinami bf22661596 Add Python 3 only classifier
Python 2 support was removed during Ussuri cycle. This change adds
the classifier to clearly state that only Python 3 is supported.

Change-Id: Ib244469e09e396ea897d1778bb1bad15cebf1f10
2022-02-08 14:06:10 +00:00
Ghanshyam Mann ed1183919a Updating python testing as per Yoga testing runtime
Yoga testing runtime[1] has been updated to add py39
testing as voting. Unit tests update are
handled by the job template change in openstack-zuul-job

- https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/820286

this commit updates the functional and tips jobs to test
on py39, also update the classifier in setup.cfg file.

[1] https://governance.openstack.org/tc/reference/runtimes/yoga.html

Change-Id: I6e1c64961f0feb920e45ef6a6ed29f2e32265768
2021-12-13 20:57:28 -06:00
Stephen Finucane 870f130989 setup.cfg: Fix errant key
The author of change I08c014e10c3fc54046930ea8be2b13775428e51b fat
fingered the replacement of 'python-requires' with 'python_requires'
resulting in the following warning:

  UserWarning: Usage of dash-separated 'python-r_quires' will not be
  supported in future versions. Please use the underscore name
  'python_r_quires' instead

Not sure how setuptools was still identifying but resolve it
nonetheless.

Related-Bug: #1939716

Change-Id: I293919d6dc93bf221eae9109fd4a658d332bdca8
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2021-08-12 15:40:14 +00:00
Stephen Finucane ae43625781 db: Remove "support" for configurable migration backends
This doesn't actually do anything, and hasn't since we merged change
I77921366a05ba6f9841143af89c1f4059d8454c6 way back in Ocata. Drop it.

Change-Id: I623b2ffb8bdd72525241835b5d1164c275f9fe73
Implements: blueprint remove-sqlalchemy-migrate
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2021-07-13 17:19:33 +01:00
Yandong Xuan ebb6257cc7 setup.cfg: Replace dashes with underscores
Resolves warnings like the following:

  UserWarning: Usage of dash-separated 'description-file' will not be
  supported in future versions. Please use the underscore name
  'description_file' instead

Change-Id: I08c014e10c3fc54046930ea8be2b13775428e51b
2021-05-01 16:02:01 +08:00
Ghanshyam Mann c107629f90 [goal] Deprecate the JSON formatted policy file
As per the community goal of migrating the policy file
the format from JSON to YAML[1], we need to do two things:

1. Change the default value of '[oslo_policy] policy_file''
config option from 'policy.json' to 'policy.yaml' with
upgrade checks.

2. Deprecate the JSON formatted policy file on the project side
via warning in doc and releasenotes.

Also convert the ./glance/tests/etc/policy.json to policy.yaml
file. Replace policy.json to policy.yaml ref from doc and tests.

[1]https://governance.openstack.org/tc/goals/selected/wallaby/migrate-policy-format-from-json-to-yaml.html

Depends-On: https://review.opendev.org/c/openstack/nova/+/773192
Change-Id: I17d0374dd4223688e5f95253802a4ae87377953a
2021-01-29 15:31:47 -08:00
likui a8fb4e2587 Remove babel.cfg etc
Remove babel.cfg and the translation bits from setup.cfg, those are not
needed anymore.

Change-Id: I221173c724d23c1221febb8928c67bae1150bf5e
2020-09-03 15:01:23 +08:00
Erno Kuvaja 673666cbf4 Deprecation cleanout Registry and related
This patch removes majority of the registry and it's related
endpoints and config options that has been deprecated for
removal in various releases.

Change-Id: I75014bd50bf382efebe56bd89c20ffefbdde25f5
2020-06-30 20:41:30 +01:00
Sean McGinnis 4505f5d69b
Add py38 package metadata
Now that we are running the Victoria tests that include a
voting py38, we can now add the Python 3.8 metadata to the
package information to reflect that support.

Change-Id: I961af5693debacf7e29021a96e2c2b7d510da991
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-04-24 08:22:34 -05:00
Andreas Jaeger 176d24de94 Cleanup old cruft
Make a few cleanups:
- Remove python 2.7 stanza from setup.py
- Update requirements: Remove sphinx, it's not needed for testing, add
  pygments which is really needed.
- Update doc/requirements: Remove python 2.7 support
- tox.ini: Remove testing of po files, the infra scripts do this since
  a long time
- Update conf.py, no need to import openstackdocstheme anymore.

Change-Id: I9d030eb450f2c7ae74c25b7564a01b8785503e5e
2020-03-28 08:18:01 +01:00
Erno Kuvaja e0c5440819 Add decompression import plugin
Supported compression formats initially are:
* zip
* gzip
* lha/lzh _if_ lhafile is installed

Change-Id: Id125ebb5e8a9b22a8797d3158e60451d80bfaa14
2020-03-26 15:44:59 +00:00
Andrii Ostapenko c7ddabb15f Remove policy.json from setup.cfg
python setup.py install fails due to https://review.opendev.org/#/c/694387
unable to copy missing file.

Change-Id: Ib02387c4be70581df64cf5009750b4f30ae30159
2020-03-05 23:23:58 -06:00
Ian Wienand 0035ab2538 Revert "Remove all example configs for deprecated registry"
This reverts commit 2a28696de9.

Devstack still references a number of these files; revert until
devstack incorporates removal.

Change-Id: I1e90ceee1f87291668e447f180f37bb809763836
2020-02-14 14:30:44 +11:00
Erno Kuvaja 2a28696de9 Remove all example configs for deprecated registry
Including removal if the example conf in docs.

Change-Id: I00c77b8f7001d8fa0fde4083c2ee88c370c14a09
2020-02-13 15:33:50 +00:00
Abhishek Kekane 1754c9e2b0 Copy existing image in multiple stores
Added new import method 'copy-image' which will copy existing image into
specified list of stores. Introduced additional task which will serve
as internal plugin which will allow copying existing image into staging
area and then this data will be uploaded to specified stores via regula
import flow.

NOTE: This new import method 'copy-image' is only supported if multiple
stores are enabled in deployment.

APIImpact
Implements: blueprint copy-existing-image
Change-Id: I13eaab7ab013f44ce18465bdbdbe8052942570ff
2020-02-12 05:32:46 +00:00
Zane Bitter 5c17e4c7ef Move policy defaults into code
Instead of a default policy.json file, policy defaults are now defined
in code. An operator need not supply policy.json data except to the
extent they want to override the defaults. Currently an empty
policy.json is still shipped because it is expected by devstack, but
this can be removed later. A sample policy.yaml file can be generated
using the genpolicy tox environment.

This partly fulfils the requirements of the policy in code goal[1].
However, because policies don't map 1:1 with APIs, it will not be
possible to fully document the policies until changes are made in how
policies are applied as proposed in https://review.opendev.org/528021

Due to the fact that existing policy files may rely on a rule named
"default" to specifiy policies not explicitly listed in the policy.json
file, all policies that are not admin-only by default now default to
"rule:default", so that the "default" rule will continue to apply to
those policies that are not listed in policy.json.

To ensure that this yields the expected policy in a standard
policy-in-code config file, the default value of the "default" rule is
now the empty string "". This is a change; between the Queens release
and now the default was set to "role:admin" to match the value specified
in the default policy.json file. An installation relying on both the
"default" rule for some policies and the default value of the default
rule may end up with a more permissive policy after upgrading. It's
likely that no such policies exist in the wild, because prior to the
Queens release the default value for the "default" rule was "@" (allow
all requests), so anybody relying on this rule will surely have
specified it explicitly in their policy.json.

Policies whose default is "role:admin" no longer use the "default" rule.
Therefore existing policy.json files that rely on the "default" rule for
those policies, and who have specified a value for the "default" rule
that is more permissive, will result in a more restrictive policy after
upgrading. It is unlikely that any of these policies exist in the wild
either.

[1] https://governance.openstack.org/tc/goals/selected/queens/policy-in-code.html

Change-Id: I8d1ccf5844078cc0b1652fb1130794daf07cedbc
2020-01-06 12:56:30 -05:00
Erno Kuvaja e3b8ace6a1 Add classifiers of supporting py3
Change-Id: Id316dc7d3fc18ba3f2176cd9e9b413d673046c4d
2019-12-12 13:00:15 +00:00
Erno Kuvaja ce79c8ed78 Drop support for PY27
Change-Id: I9d37f142bd5ddaeeacc441e8e7dda3da166850d9
2019-12-06 15:40:11 +00:00
Erno Kuvaja da29e129fa Revert "Add reserved stores to the sample config file"
This patch introduced double registering of the same
config option groups which fails glance-api start
if reserved stores are actually defined.

The code utilizing these config options has not been
merged which prevented testing to catch this.

Closes-Bug: #1844108

This reverts commit 4265e61bc8.

Change-Id: Iaf338d29673e68a15d37fdda81add552e4175634
2019-09-19 12:40:34 +01:00
Brian Rosmaita 4265e61bc8 Add reserved stores to the sample config file
Since we know the names of the reserved stores, we can add them
to the config file to make it easier for operators to configure
these things.

Includes deprecation of the 'work_dir' and 'node_staging_uri'
options.

Change-Id: I992cf468f9ce156ba51b1dd025459939acd8dce0
2019-08-06 10:45:43 -04:00
Cyril Roelandt 517d8d66c3 Add an oslo.policy.enforcer entrypoint
This will allow oslopolicy-policy-generator to generate useful
information about Glance policies.

Change-Id: I3aeeeb67d19832ad72f0ab06c8adc0b018020c71
Closes-Bug: #1816647
2019-02-19 20:32:11 +01:00
Zuul 4af32d0994 Merge "Update mailinglist from dev to discuss" 2018-12-18 05:40:56 +00:00
Lance Bragstad c82ecc7463 Implement scaffolding for upgrade checks
One of the community goals for Stein is to implement a command-line
tool for operators that runs programmable checks that might impact
upgradability.

This commit lays down the basic structure for the upgrade checks and
ties it up to `glance-status` command.

Change-Id: I7fcf5235a76d15dbcb2c49255bc26c2b586cd71c
Story: 2003657
Task: 26135
2018-12-05 16:43:00 -05:00
ZhongShengping 1058ad0a2d Update mailinglist from dev to discuss
openstack-dev was decomissioned this night in https://review.openstack.org/621258
Update openstack-dev to openstack-discuss

Change-Id: I6b5a3489c3e09bc1413dbac174310339151df05b
2018-12-05 09:44:29 +08:00
Zuul 070179948b Merge "Rename async package to async_" 2018-09-20 15:18:32 +00:00
Javier Pena 39ddaeb498 Remove rootwrap.conf file from setup.cfg
https://review.openstack.org/527425 removed etc/rootwrap.conf, but
it did not remove its entry on setup.cfg. Thus, any attempt to do
"python setup.py install" will fail.

Change-Id: I041551fb6efb8fd52ff1eaa55f6b4af6738c4ded
2018-08-29 10:48:38 +02:00
Corey Bryant c58e5e02af Rename async package to async_
In Python 3.7, "async" is a keyword. To prevent it from
conflicting, rename the async package to async_.

Change-Id: I1eaf87eedb86679d9ca9323aac05f0770c33efea
Closes-Bug: #1781617
2018-08-07 14:42:14 -04: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
Nguyen Hai 5e5ba92aec Follow the new PTI for document build
For compliance with the Project Testing Interface as described in:
https://governance.openstack.org/tc/reference/project-testing-interface.html
http://lists.openstack.org/pipermail/openstack-dev/2017-December/125710.html

Remove the '[build_sphinx]' and [pbr] sections as described in:
http://lists.openstack.org/pipermail/openstack-dev/2018-March/128594.html

Adds the use of sphinxcontrib.apidoc to get (mostly) the same output as what
was provided by the removed [pbr] section.

Change-Id: Ie7e3acef7161cb8f218c2333167490c8116a2122
Depends-On: https://review.openstack.org/#/c/560270/
2018-04-11 06:02:54 +00:00
Zuul abfa272c1f Merge "Adds 'web-download' import method" 2018-02-07 06:03:48 +00:00
Haikel Guemar c1930d4c93 Fix pip install failure
At install_data hook, it tries to glance-image-import.conf which
does not exist. Since it is an optional file, let's not install it
by default.

Change-Id:  I8a5122355da43c592b0cbad0eb7921875e0a5e99
2018-01-25 14:02:41 +01:00
Erno Kuvaja 223f2cf887 Adds 'web-download' import method
This change adds 'web-download' Image Import method.

Changes discovery call returning actual enabled methods rather than
hardcoded value.

Change-Id: I3960d07cfa4e1be391f7a164147611724788d83e
2018-01-24 13:01:26 +00:00
bhagyashris f5ae04b9f3 Implementation of Inject metadata properties
Implements the spec Inject metadata properties automatically
to non-admin images

This commit adds new task '_InjectImageMetadata' to inject
the metadata properties automatically to non-admin images
at the time of creation of images using newly introduce
'image-import' api in v2.

DocImpact

Implements: I6a7ed31d5fae677cbbc9a6f6053f79d3e9326561
Change-Id: I98be97c42f23b60a72d520aad5f6078a96372c59
2018-01-19 12:11:31 +05:30
Erno Kuvaja 1231fb5f6e Add hooks for Image Import plugins
This change adds hooks for pulling in plugins for
Interoperable Image Import taksflow. Boilerplate Noop
plugin is provided as an example and for testing.

Change-Id: If14c7dc4f38360006f9cb350fbba54fa2f33be61
2018-01-09 21:13:15 +00:00
Jesse Pretorius b0b102b8dc Add default configuration files to data_files
In order to make it simpler to use the default
configuration files when deploying services
from source, the files are added to pbr's
data_files section so that the files are
included in the built wheels and therefore
deployed with the code. Packaging and deployment
tools can then more easily use the default files
if they wish to.

This pattern is already established with similar
files for neutron and the glance metadefs as has
been mentioned in the related bug report.

Change-Id: Ie0eb7f16bc975de0db80a2144fd8db9e09f6317f
Closes-Bug: #1718356
2017-09-21 17:39:43 +00:00
Jenkins 02cd5cba70 Merge "Update URL home-page in documents according to document migration" 2017-08-28 18:40:43 +00:00
Brian Rosmaita 4366a7493c Fix api_image_import tasks stuck in 'pending'
The immediate cause was that the api_image_import flow was not
listed in the entrypoints in setup.cfg, so stevedore couldn't find
it.  After the entrypoint was added, the task was going to failure
because it couldn't find the image_id.  So this patch has the
import controller add the image_id to the task_input dict.  Next
the flows were having trouble finding the image_id, so I just
passed it to them.  There's probably a more elegant way to have
taskflow handle this, so this patch could use a refactoring.  On
the plus side, the interoperable image import process does appear
to work with this patch.

NOTE: if you want to test this in devstack, use the stable/ocata
devstack but with the master branch of glance.  The tasks engine
doesn't appear to be running under the Pike devstack configuration.
(Use defect 1712463 if you have an idea what might be the problem.)

Change-Id: Ic68c17f4cb671eb664e2de331787b55fe9878a27
Closes-bug: #1712462
2017-08-23 14:12:43 -04:00
Luong Anh Tuan 545fff51f3 Update URL home-page in documents according to document migration
Change-Id: I8970c2d67cfefc8c094e2bb4b6e0ca5e5853ca73
2017-07-14 02:55:12 +00:00
Stephen Finucane 1da56883f5 doc: Explicitly set 'builders' option
A recent release of pbr explicitly requires stating which builders are
requested, rather than defaulting to html and man. This has resulted in
man pages not being built. Correct this oversight, along with a few
issues that have been introduced to 'doc/source/conf.py' since. It is
also necessary to remove a couple of plugins as there seems to be
another pbr bug under the hood. Fortunately none of these are used so
it's all good.

Change-Id: I22fd4d113704949dbf7704f50fa1d08fa10f11b6
2017-07-07 17:52:25 +00:00
Doug Hellmann f9c8f860f3 turn on warning-is-error for sphinx build
Change-Id: I325346f580bb85ffc8834df66a1f2e4a4664dbc7
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2017-06-29 13:59:47 +00:00
Doug Hellmann a2df410e76 fix the autodoc instructions
Use autodoc_index_modules instead of autodoc_tree_index_modules so only
one copy of the API docs are generated.

Exclude the tests subpackage because it's not part of the Glance Python
API.

Exclude the glance.db.sqlalchemy subpackage to avoid issues caused when
parts of it cannot be imported during the doc build because they rely on
alembic setting up values that are not configured for a simple import.

Change-Id: I127b812bc879fc39533b39df1785d93835142430
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2017-06-21 14:15:58 -04:00
Doug Hellmann 1c7f556d4f rearrange existing documentation to follow the new layout standard
This change moves existing files, updates a few of the cross-references
and paths, and fixes some formatting. It is not meant to be the final
word on how the main page looks or how the other files are organized,
but it gets everything roughly into shape. If the glance team wants to
make changes, please do those as follow-up patches

This change depends on the spec and on a feature of pbr that allows us
to move where the auto-generated class reference documentation ends up
in the tree.

Depends-On: Ia750cb049c0f53a234ea70ce1f2bbbb7a2aa9454
Depends-On: I2bd5652bb59cbd9c939931ba2e7db1b37d2b30bb
Change-Id: I9dde267793a5913acb5b1ec028cfb66bc5189783
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2017-06-21 14:15:58 -04:00
Matthew Treinish 5e260055fa
Add pbr wsgi script entrypoint to glance
This commit adds a pbr entrypoint for the wsgi script file. This enables
deploying glance as a proper wsgi application instead of a standalone
service.

Change-Id: I089a22a4be4227a551c32442dba27c426f54c87d
2017-06-18 03:52:20 -04:00
Javier Pena ce92edafd2 Remove glare leftovers from setup.cfg
I3026ca6287a65ab5287bf3843f2a9d756ce15139 removed Glare from the Glance
codebase, but left some lines in setup.cfg.

This patch removes the remnant of the references in the code tree.

Co-Authored-By: Javier Pena <jpena@redhat.com>
Co-Authored-By: Nikhil Komawar <nik.komawar@gmail.com>

Depends-on: I02bfe805c419fcc49ac43b66f4f7b1a0d1d54755
Change-Id: Ia3652eb0dede3614cc4ea880f8ddc06c95740797
2017-03-04 15:59:29 +00:00
Tom Cocozzello 99cece5fdd revert warnerrors before gate breaks
warnerrors used to show the errors in output when the docs generate
but now it looks like when this patch lands [0] it will cause the gate
to fail. I will push up a patch to fix all the docs problems but we
should revert this so we don't have a day when the gate is broken.

[0] https://review.openstack.org/#/c/229951

Change-Id: Ica33f1fd5acdc17a115d7a3bd81f8f4d79c1a809
2016-03-14 09:17:13 -04:00