968 Commits

Author SHA1 Message Date
Hervé Beraud
63e7072a89 drop mock from lower-constraints
The mock third party library was needed for mock support in py2
runtimes. Since we now only support py36 and later, we don't need it
in lower-constraints.

These changes will help us to drop `mock` from openstack/requirements

Change-Id: I264cfc61d6f20ac0842931b793bf72935fdd550d
2020-06-09 01:19:35 +02:00
Zuul
a6e231f876 Merge "Remove six" 2020-06-08 13:47:00 +00:00
Zuul
3bd07c557c Merge "Cap jsonschema 3.2.0 as the minimal version" 2020-06-03 16:37:37 +00:00
Andreas Jaeger
e544677d39 Switch to newer openstackdocstheme and reno versions
Switch to openstackdocstheme 2.2.1 and reno 3.1.0 versions. Using
these versions will allow especially:
* Linking from HTML to PDF document
* Allow parallel building of documents
* Fix some rendering problems

Update Sphinx version as well.

Disable openstackdocs_auto_name to use 'project' variable as name.

Change pygments_style to 'native' since old theme version always used
'native' and the theme now respects the setting and using 'sphinx' can
lead to some strange rendering.

openstackdocstheme renames some variables, so follow the renames
before the next release removes them. A couple of variables are also
not needed anymore, remove them.

See also
http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014971.html

Change-Id: If74b848e1f63a0e116737553fec8ab76d63457f5
2020-05-30 18:41:53 +02:00
gugug
075a8cb96b Remove six
We don't need this in a Python 3-only world.

Change-Id: I14ed209a18ab572c073400fabdd28fd639d55240
2020-05-28 00:03:18 +08:00
Hervé Beraud
4cf3d16522 Cap jsonschema 3.2.0 as the minimal version
Previous versions of jsonschema (<3.2.0) doesn't support python 3.8 [1].
Python 3.8 is part of the victoria supported runtimes [2] so we now force
to use jsonschema version 3.2.0 to avoid issues, remove ambiguity and ensure
that everything works with python 3 in general.

[1] https://github.com/Julian/jsonschema/pull/627
[2] https://governance.openstack.org/tc/reference/runtimes/victoria.html#python-runtimes-for-victoria

Change-Id: Ib5308485e50cc076855cc8e1df72b02d208febe1
2020-05-26 21:52:07 +02:00
Zuul
4c445c2198 Merge "Fix pygments style" 2020-05-26 15:23:25 +00:00
Zuul
de1057c9e6 Merge "Add releasenotes link to README" 2020-05-26 12:32:30 +00:00
jacky06
036703c8d4 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found.

Change-Id: I71b869fc509cb46b55b1e88fae20422bcba085f7
2020-05-23 00:03:51 +00:00
gugug
7524152766 Fix pygments style
New theme of docs respects pygments_style.

more info: http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014971.html


Change-Id: I26b15daf38616c29ac4b2cf0f68be6eb975577cb
2020-05-21 01:18:39 +00:00
Zuul
5c03de1668 Merge "Replace git.openstack.org URLs with opendev.org URLs" 2020-05-19 08:08:30 +00:00
lidong
fcdb395e76 Add releasenotes link to README
Change-Id: I37f2acd77a953c67e18f0772cd1aa3d47e62f6a0
2020-05-19 06:30:05 +00:00
gujin
910f2e72db Replace git.openstack.org URLs with opendev.org URLs
Thorough replacement of git.openstack.org URLs with their opendev.org counterparts.

Change-Id: Ia04c82127761ee818a37efe6cf9137987f8262f8
2020-05-17 04:38:56 +00:00
melissaml
085fb3c9c5 Remove translation sections from setup.cfg
These translation sections are not needed anymore, Babel can
generate translation files without them.

Change-Id: I6478639b17968e5eb5e44ffcbca2ca65cbc995f7
2020-05-14 17:51:40 +08:00
afecf766f5 Add Python3 victoria unit tests
This is an automatically generated patch to ensure unit testing
is in place for all the of the tested runtimes for victoria.

See also the PTI in governance [1].

[1]: https://governance.openstack.org/tc/reference/project-testing-interface.html

Change-Id: Ibd57244400306ed8b976f61c3e45428e537b098c
2020-04-22 16:25:08 +00:00
e6541de2bd Update master for stable/ussuri
Add file to the reno documentation build to show release notes for
stable/ussuri.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/ussuri.

Change-Id: I0c83a8eedb3e50c2dc39c7d690f3457aecebf585
Sem-Ver: feature
2020-04-22 16:25:06 +00:00
Sean McGinnis
bf8a79a5e1
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: I9357128c04f2fe0284432c1f6a543d63309efda3
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
5.0.0 5.0.0.0rc1
2020-04-18 11:53:56 -05:00
Andreas Jaeger
d63d664b28 Fix doc building
Use sphinx-build, this fixes doc building so that the generated content
is available for publishing again.

(change I0dbb13d555eb473916ba585c62a0f7433d15afed broke this)

Change-Id: Ib7c6b7437abc0b5c500a5afdaaf79a045f7df9fe
2020-04-06 14:48:39 +02:00
Andreas Jaeger
bfbaea9749 Cleanup py27 support
Make a few cleanups:
- Remove python 2.7 stanza from setup.py
- Add requires on python >= 3.6 to setup.cfg so that pypi and pip
  know about the requirement
- Remove obsolete sections from setup.cfg:
  * Wheel is not needed for python 3 only repo
  * Some other sections are obsolete
- Update classifiers
- Update requirements, no need for python_version anymore

Change-Id: I0dbb13d555eb473916ba585c62a0f7433d15afed
2020-04-05 09:21:00 +02:00
Sean McGinnis
21e4e3455a
Uncap jsonschema
Global requirements has uncapped jsonschema, so we need to do so here
too.

Change-Id: I525215e95ebe4b155a17e0e187e9aca27a8217bb
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-03-13 13:58:37 -05:00
Zuul
559e89b069 Merge "Update docs and scripts for using python3" 2020-02-26 12:06:43 +00:00
Hongbin Lu
62ff2f9f58 Fix test_container_ipam_request_address_with_existing_port
Closes-Bug: #1864330
Change-Id: Iecd61c0ba0c9ae789b3cf771dc435d7b9513a339
2020-02-22 21:33:00 +00:00
Hongbin Lu
d9523c7afe Update docs and scripts for using python3
Python2 is deprecated so we need to switch to python3

Change-Id: Id9158df88f0b6ed0c071994bf0aa240063ac6761
2020-02-17 16:15:11 +00:00
Hongbin Lu
97266ff5b9 Retry a few times on listing extensions
Listing neutron extensions is part of the startup process.
During system reboot, kuryr-libnetwork process might start before
the neutron processes, which leads to failure on listing neutron
extensions thus failing the kuryr process.

We need to be robust on startup. This commit will retry a few
times on listing extensions to handle this case.

Change-Id: I18a2a6c057225e30ba7e03e1377ab88884d8d2bd
Related-Bug: #1850936
2019-11-30 20:06:28 +00:00
Ghanshyam Mann
46e1cbfc39 [ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

kuryr-libnetwork is ready with python 3 and ok to drop the
python 2.7 support.

Complete discussion & schedule can be found in
- http://lists.openstack.org/pipermail/openstack-discuss/2019-October/010142.html
- https://etherpad.openstack.org/p/drop-python2-support

Ussuri Communtiy-wide goal:
https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html

Depends-On: https://review.opendev.org/#/c/693631/
Change-Id: I3776d17e05b565e05f84266eef0df15374a43a89
2019-11-16 17:10:37 +00:00
zhangboye
fc7cc09604 Switch to Ussuri jobs
Change-Id: I959bc199ebf9bbdbc9534c9efe4e833494befb02
2019-10-25 13:49:21 +08:00
Zuul
a3f8bf7dde Merge "[train][goal] Define new kuryr-libnetwork-fullstack-ipv6-only job" 2019-10-03 03:31:20 +00:00
Zuul
9f254e5103 Merge "Update master for stable/train" 2019-10-03 01:27:45 +00:00
Hongbin Lu
46442db3a2 Fix unit tests CI job
Change-Id: I7f5ec495c91b79f65f73528600372405e2003899
2019-09-23 10:06:46 +00:00
1e76a4a5b8 Update master for stable/train
Add file to the reno documentation build to show release notes for
stable/train.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/train.

Change-Id: If7e2c4c5c8046ed4eb19fc0f318e386693388a97
Sem-Ver: feature
2019-09-23 08:58:14 +00:00
Ghanshyam Mann
310d710b4a [train][goal] Define new kuryr-libnetwork-fullstack-ipv6-only job
As part of Train community goal 'Support IPv6-Only Deployments and Testing'[1],
we need to define the integration job which deploy services
on IPv6 and perform testing to make sure service listen and communicate
over IPv6 properly.

kuryr-libnetwork has legacy zuul jobs only so base zuulv3 IPv6 job 'devstack-ipv6' and
'devstack-tempest-ipv6' cannot be used and we have to copy the whole
run.yaml to set the IPv6 setting and run the IPv6 verification
script via post_test_hook.

This commit adds the new job 'kuryr-libnetwork-fullstack-ipv6-only'
run on gate and set the required IPv6 setting'.

Story: #2005477
Task: # 35900

[1] https://governance.openstack.org/tc/goals/train/ipv6-support-and-testing.html

Change-Id: Ic483a5b4aaff90f05b23d23ffd573ee3626ee46c
2019-09-20 01:38:48 +00:00
Zuul
622ded3e28 Merge "Fix ipv6 issue on devstack" 4.0.0.0rc1 4.0.0 2019-08-22 11:54:23 +00:00
Hongbin Lu
b63cd9ae4d Fix ipv6 issue on devstack
Change-Id: I1450759319d82d3533d887e45d01b4185256786a
Story: #2005477
Task: #35942
2019-08-22 01:07:06 +00:00
Zuul
97238026f6 Merge "Add Python 3 Train unit tests" 2019-08-14 14:10:34 +00:00
Andreas Jaeger
f55538348c Update api-ref location
The api documentation is now published on docs.openstack.org instead
of developer.openstack.org. Update all links that are changed to the
new location. This also updates some ancient links.

Note that redirects will be set up as well but let's point now to the
new location.

For details, see:
http://lists.openstack.org/pipermail/openstack-discuss/2019-July/007828.html

Change-Id: I1465f265e631c7f3c55cc0634ec3516b40d5bc83
2019-07-25 17:59:18 +02:00
Corey Bryant
86b6bf3432 Add Python 3 Train unit tests
This is a mechanically generated patch to ensure unit testing is in place
for all of the Tested Runtimes for Train.

See the Train python3-updates goal document for details:
https://governance.openstack.org/tc/goals/train/python3-updates.html

Change-Id: Id4296e5cb3556d7568bcdb267d4dbd156815a24b
Story: #2005924
Task: #34217
2019-07-05 11:41:55 -04:00
Zuul
5264dee964 Merge "Update install guide for master branch" 2019-05-08 10:30:27 +00:00
Hongbin Lu
c528e9be2f Replace port 35357 with port 5000
Starting from Keystone v3, the port 35357 is not used.
See: https://review.opendev.org/#/c/541857/

Change-Id: I4fee6ebcca6cbb1c610fa19c4294ef5a45b50709
2019-04-29 22:17:03 +00:00
Hongbin Lu
01b20b1af1 Update install guide for master branch
Change-Id: I7ec366c59eda13c0483e3cae185c263e40694bac
2019-04-27 16:13:51 +00:00
OpenDev Sysadmins
9665dafdd1 OpenDev Migration Patch
This commit was bulk generated and pushed by the OpenDev sysadmins
as a part of the Git hosting and code review systems migration
detailed in these mailing list posts:

http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html

Attempts have been made to correct repository namespaces and
hostnames based on simple pattern matching, but it's possible some
were updated incorrectly or missed entirely. Please reach out to us
via the contact information listed at https://opendev.org/ with any
questions you may have.
2019-04-19 19:35:51 +00:00
Ghanshyam Mann
ca8160ea7b Dropping the py35 testing
All the integration testing has been moved to
Bionic now[1] and py3.5 is not tested runtime for
Train or stable/stein[2].

As per below ML thread, we are good to drop the py35
testing now:
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/005097.html

[1] http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004647.html
[2]
https://governance.openstack.org/tc/reference/runtimes/stein.html
https://governance.openstack.org/tc/reference/runtimes/train.html

Change-Id: I3548290d55fda3a1192fcefb3019c35f60d5b751
2019-04-15 18:38:09 +00:00
0c148b9bbf Update master for stable/stein
Add file to the reno documentation build to show release notes for
stable/stein.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/stein.

Change-Id: I9e798acfff7657af8be0c67af7b6fab635803b79
Sem-Ver: feature
2019-03-27 11:09:55 +00:00
Ian Wienand
2c59972431 Replace openstack.org git:// URLs with https://
This is a mechanically generated change to replace openstack.org
git:// URLs with https:// equivalents.

This is in aid of a planned future move of the git hosting
infrastructure to a self-hosted instance of gitea (https://gitea.io),
which does not support the git wire protocol at this stage.

This update should result in no functional change.

For more information see the thread at

 http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003825.html

Change-Id: I2a2cec67b3b3dd7f321f889ce3ae6acb5a65460d
2019-03-24 20:34:04 +00:00
Marcin Juszkiewicz
be3755864a README: make it us-ascii
without it:

()[root@ec6e7972d313 kuryr-libnetwork-3.0.1.dev2]# pip install .
Processing /kuryr-libnetwork-source/kuryr-libnetwork-3.0.1.dev2
    Complete output from command python setup.py egg_info:
    ERROR:root:Error parsing
    Traceback (most recent call last):
      File "/var/lib/kolla/venv/lib/python3.6/site-packages/pbr/core.py", line 96, in pbr
        attrs = util.cfg_to_args(path, dist.script_args)
      File "/var/lib/kolla/venv/lib/python3.6/site-packages/pbr/util.py", line 256, in cfg_to_args
        pbr.hooks.setup_hook(config)
      File "/var/lib/kolla/venv/lib/python3.6/site-packages/pbr/hooks/__init__.py", line 25, in setup_hook
        metadata_config.run()
      File "/var/lib/kolla/venv/lib/python3.6/site-packages/pbr/hooks/base.py", line 27, in run
        self.hook()
      File "/var/lib/kolla/venv/lib/python3.6/site-packages/pbr/hooks/metadata.py", line 26, in hook
        self.config['name'], self.config.get('version', None))
      File "/var/lib/kolla/venv/lib/python3.6/site-packages/pbr/packaging.py", line 831, in get_version
        version = _get_version_from_pkg_metadata(package_name)
      File "/var/lib/kolla/venv/lib/python3.6/site-packages/pbr/packaging.py", line 799, in _get_version_from_pkg_metadata
        pkg_metadata = email.message_from_file(pkg_metadata_file)
      File "/usr/lib/python3.6/email/__init__.py", line 54, in message_from_file
        return Parser(*args, **kws).parse(fp)
      File "/usr/lib/python3.6/email/parser.py", line 54, in parse
        data = fp.read(8192)
      File "/var/lib/kolla/venv/lib/python3.6/encodings/ascii.py", line 26, in decode
        return codecs.ascii_decode(input, self.errors)[0]
    UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 3612: ordinal not in range(128)
    error in setup command: Error parsing /tmp/pip-req-build-cckcsjoj/setup.cfg: UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 3612: ordinal not in range(128)

Change-Id: I1585704e39b19e95c3d1e53cfb60c80825768237
2019-03-19 11:29:11 +01:00
ghanshyam
1fb4c1a3a0 Migrate legacy jobs to Ubuntu Bionic
We have migrated the zuulv3 job to Bionic during Dec/Jan month.
 - http://lists.openstack.org/pipermail/openstack-discuss/2018-December/000837.html
 - https://etherpad.openstack.org/p/devstack-bionic
But that effort does not move all gate job to Bionic as there are
large amount of jobs are still legacy jobs. All the legacy jobs still
use Xenial as nodeset.

As per the decided runtime for Stein, we need to test everything on openstack
CI/CD on Bionic - https://governance.openstack.org/tc/reference/runtimes/stein.html

Below patch move the legacy base jobs to bionic which will move the derived jobs
automatically to bionic. These jobs are modified with branch variant so that they will use
Bionic node from stein onwards and xenial for all other stable branches
until stable/rocky.
- https://review.openstack.org/#/c/639096

This commit remove the overridden nodeset from legacy jobs
so that it will start using the nodeset defined in parent job.

More Details: 
- https://etherpad.openstack.org/p/legacy-job-bionic
- http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003614.html

Depends-On: https://review.openstack.org/#/c/639096
Change-Id: Ia9e89689b4bfff8ce5fcb7c577c18b1b20e11686
2019-03-13 04:27:55 +00:00
ZhongShengping
e028d0c178 add python 3.7 unit test job
This is a mechanically generated patch to add a unit test job running
under Python 3.7.

See ML discussion here [1] for context.

[1] http://lists.openstack.org/pipermail/openstack-dev/2018-October/135626.html

Change-Id: I76107a34b44c53835a7d6a4cd6828e8d76077e7d
Story: #2004073
Task: #27424
2019-02-19 17:05:56 +08:00
Hongbin Lu
5fb8275d12 Don't update existing port if no change
This allows external service pre-create a neutron port with
'binding:host_id' populated before passing the port to kuryr.
This is important because setting 'binding:host_id' is slow.
This blocks the docker daemon for serving other requests,
which blocks the whole system.
We want to have this field pre-populated so that the docker
daemon won't be blocked by this API call.

This commit also allows the 'device_owner' field to be
customized if users choose to pre-populate the 'binding:host_id'
field. In addition, this commit skips the API call to update the
neutron port if the 'binding:host_id' is pre-populated
and 'admin_state_up' and 'mac_address' fields are unchanged.

Closes-Bug: #1809306
Change-Id: I09c4a51410dffaec21ab0bb3db85df8c776c92e5
3.0.0
2019-01-19 22:57:11 +00:00
Hongbin Lu
a9a70b3178 Avoid changing name of existing ports
In before, we renamed existing neutron ports in order to make
the ports searchable by using endpoint_id.
However, user experience is bad on such renaming because the original
name is lost. This commit proposes to use tagging approach instead.
In particular, we tag the endpoint_id to the existing ports so that
the ports are still searchable by using tags.

Closes-Bug: #1810219
Change-Id: I9930f3bcc3a6dbf4b23bf8488f08655bc43b5ba8
2019-01-01 22:59:25 +00:00
Hongbin Lu
b194b0732f Untag resource if it was tagged
On removing a tag to a resource (port/subnet/subnetpool/network),
if the resource doesn't have the tag, skip the neutron API call to
remove_tag because the tags will be unchanged.
This will avoid one or two Neutron API calls and optimize the
performance a bit.

Partial-Bug: #1809306
Change-Id: Iffa5fbf27c64f1aad0a9bb97da9c4e7c5015a196
2018-12-23 19:12:03 +00:00
Hongbin Lu
dc3cf2cc93 Tag resource if it was not tagged
On adding a tag to a resource (port/subnet/subnetpool/network),
if the resource already has the tag, skip the neutron API call to
add_tag because the tags will be unchanged.
This will avoid one or two Neutron API calls and optimize the
performance a bit.

Partial-Bug: #1809306
Change-Id: I8a181d6af5228007d36fa8b217fec7f766dd37fd
2018-12-23 17:14:46 +00:00