Skip to content

Commit

Permalink
Merge pull request #7625 from nelljerram/openstack-yoga
Browse files Browse the repository at this point in the history
Update OpenStack dependencies to Yoga
  • Loading branch information
nelljerram committed May 5, 2023
2 parents b8051f8 + a6032e4 commit 286ff5d
Show file tree
Hide file tree
Showing 10 changed files with 146 additions and 19 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@ hack/test/kind/kubectl
hack/test/kind/*kubeconfig.yaml
pod2daemon/node-driver-registrar/

/networking-calico/upper-constraints.txt
/networking-calico/upper-constraints*.txt
42 changes: 39 additions & 3 deletions .semaphore/semaphore-scheduled-builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -666,7 +666,7 @@ blocks:
commands:
- ../.semaphore/run-and-monitor ci.log make ci

- name: 'networking-calico'
- name: 'OpenStack integration (Ussuri)'
run:
when: "true or change_in(['/networking-calico/'])"
dependencies: ["Prerequisites"]
Expand All @@ -679,9 +679,9 @@ blocks:
commands:
- cd networking-calico
jobs:
- name: 'Unit and FV tests (tox)'
- name: 'Unit and FV tests (tox) on Ussuri'
commands:
- ../.semaphore/run-and-monitor tox.log make tox
- ../.semaphore/run-and-monitor tox.log make tox-ussuri
- name: 'Mainline ST (DevStack + Tempest) on Ussuri'
commands:
- git checkout -b devstack-test
Expand All @@ -702,6 +702,42 @@ blocks:
- sudo journalctl > logs/journalctl.txt
- artifact push job --expire-in 1d logs

- name: 'OpenStack integration (Yoga)'
run:
when: "true or change_in(['/networking-calico/'])"
dependencies: ["Prerequisites"]
task:
agent:
machine:
type: e1-standard-4
os_image: ubuntu2004
prologue:
commands:
- cd networking-calico
jobs:
- name: 'Unit and FV tests (tox) on Yoga'
commands:
- ../.semaphore/run-and-monitor tox.log make tox-yoga
- name: 'Mainline ST (DevStack + Tempest) on Yoga'
commands:
# For some reason python3-wrapt is pre-installed on a Semaphore ubuntu2004 node, but with
# a version (1.11.2) that is different from the version that OpenStack needs (1.13.3), and
# this was causing the DevStack setup to fail, because pip doesn't know how to uninstall
# or replace the existing version. Happily we do know that, so let's do it upfront here.
- sudo apt-get remove -y python3-wrapt || true
- git checkout -b devstack-test
- export LIBVIRT_TYPE=qemu
- export UPPER_CONSTRAINTS_FILE=https://releases.openstack.org/constraints/upper/yoga
- export NC_PLUGIN_REPO=$(dirname $(pwd))
- export NC_PLUGIN_REF=$(git rev-parse --abbrev-ref HEAD)
- TEMPEST=true DEVSTACK_BRANCH=stable/yoga ./devstack/bootstrap.sh
epilogue:
on_fail:
commands:
- mkdir logs
- sudo journalctl > logs/journalctl.txt
- artifact push job --expire-in 1d logs

after_pipeline:
task:
jobs:
Expand Down
42 changes: 39 additions & 3 deletions .semaphore/semaphore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -666,7 +666,7 @@ blocks:
commands:
- ../.semaphore/run-and-monitor ci.log make ci

- name: 'networking-calico'
- name: 'OpenStack integration (Ussuri)'
run:
when: "false or change_in(['/networking-calico/'])"
dependencies: ["Prerequisites"]
Expand All @@ -679,9 +679,9 @@ blocks:
commands:
- cd networking-calico
jobs:
- name: 'Unit and FV tests (tox)'
- name: 'Unit and FV tests (tox) on Ussuri'
commands:
- ../.semaphore/run-and-monitor tox.log make tox
- ../.semaphore/run-and-monitor tox.log make tox-ussuri
- name: 'Mainline ST (DevStack + Tempest) on Ussuri'
commands:
- git checkout -b devstack-test
Expand All @@ -702,6 +702,42 @@ blocks:
- sudo journalctl > logs/journalctl.txt
- artifact push job --expire-in 1d logs

- name: 'OpenStack integration (Yoga)'
run:
when: "false or change_in(['/networking-calico/'])"
dependencies: ["Prerequisites"]
task:
agent:
machine:
type: e1-standard-4
os_image: ubuntu2004
prologue:
commands:
- cd networking-calico
jobs:
- name: 'Unit and FV tests (tox) on Yoga'
commands:
- ../.semaphore/run-and-monitor tox.log make tox-yoga
- name: 'Mainline ST (DevStack + Tempest) on Yoga'
commands:
# For some reason python3-wrapt is pre-installed on a Semaphore ubuntu2004 node, but with
# a version (1.11.2) that is different from the version that OpenStack needs (1.13.3), and
# this was causing the DevStack setup to fail, because pip doesn't know how to uninstall
# or replace the existing version. Happily we do know that, so let's do it upfront here.
- sudo apt-get remove -y python3-wrapt || true
- git checkout -b devstack-test
- export LIBVIRT_TYPE=qemu
- export UPPER_CONSTRAINTS_FILE=https://releases.openstack.org/constraints/upper/yoga
- export NC_PLUGIN_REPO=$(dirname $(pwd))
- export NC_PLUGIN_REF=$(git rev-parse --abbrev-ref HEAD)
- TEMPEST=true DEVSTACK_BRANCH=stable/yoga ./devstack/bootstrap.sh
epilogue:
on_fail:
commands:
- mkdir logs
- sudo journalctl > logs/journalctl.txt
- artifact push job --expire-in 1d logs

after_pipeline:
task:
jobs:
Expand Down
42 changes: 39 additions & 3 deletions .semaphore/semaphore.yml.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -664,7 +664,7 @@ blocks:
commands:
- ../.semaphore/run-and-monitor ci.log make ci

- name: 'networking-calico'
- name: 'OpenStack integration (Ussuri)'
run:
when: "${FORCE_RUN} or change_in(['/networking-calico/'])"
dependencies: ["Prerequisites"]
Expand All @@ -677,9 +677,9 @@ blocks:
commands:
- cd networking-calico
jobs:
- name: 'Unit and FV tests (tox)'
- name: 'Unit and FV tests (tox) on Ussuri'
commands:
- ../.semaphore/run-and-monitor tox.log make tox
- ../.semaphore/run-and-monitor tox.log make tox-ussuri
- name: 'Mainline ST (DevStack + Tempest) on Ussuri'
commands:
- git checkout -b devstack-test
Expand All @@ -700,6 +700,42 @@ blocks:
- sudo journalctl > logs/journalctl.txt
- artifact push job --expire-in 1d logs

- name: 'OpenStack integration (Yoga)'
run:
when: "${FORCE_RUN} or change_in(['/networking-calico/'])"
dependencies: ["Prerequisites"]
task:
agent:
machine:
type: e1-standard-4
os_image: ubuntu2004
prologue:
commands:
- cd networking-calico
jobs:
- name: 'Unit and FV tests (tox) on Yoga'
commands:
- ../.semaphore/run-and-monitor tox.log make tox-yoga
- name: 'Mainline ST (DevStack + Tempest) on Yoga'
commands:
# For some reason python3-wrapt is pre-installed on a Semaphore ubuntu2004 node, but with
# a version (1.11.2) that is different from the version that OpenStack needs (1.13.3), and
# this was causing the DevStack setup to fail, because pip doesn't know how to uninstall
# or replace the existing version. Happily we do know that, so let's do it upfront here.
- sudo apt-get remove -y python3-wrapt || true
- git checkout -b devstack-test
- export LIBVIRT_TYPE=qemu
- export UPPER_CONSTRAINTS_FILE=https://releases.openstack.org/constraints/upper/yoga
- export NC_PLUGIN_REPO=$(dirname $(pwd))
- export NC_PLUGIN_REF=$(git rev-parse --abbrev-ref HEAD)
- TEMPEST=true DEVSTACK_BRANCH=stable/yoga ./devstack/bootstrap.sh
epilogue:
on_fail:
commands:
- mkdir logs
- sudo journalctl > logs/journalctl.txt
- artifact push job --expire-in 1d logs

after_pipeline:
task:
jobs:
Expand Down
16 changes: 13 additions & 3 deletions networking-calico/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,18 @@ include ../metadata.mk
# TODO: Release
###############################################################################

export BUILDKIT_PROGRESS=plain

tox:
curl -L https://releases.openstack.org/constraints/upper/ussuri -o upper-constraints.txt
sed -i '/etcd3gw/d' upper-constraints.txt
docker build -t networking-calico-test .
docker run -it --user `id -u`:`id -g` -v `pwd`:/code -w /code -e HOME=/code --rm networking-calico-test tox
docker run -it --user `id -u`:`id -g` -v `pwd`:/code -w /code -e HOME=/code -e PIP_CONSTRAINT --rm networking-calico-test tox

tox-ussuri:
curl -L https://releases.openstack.org/constraints/upper/ussuri -o upper-constraints-ussuri.txt
sed -i '/etcd3gw/d' upper-constraints-ussuri.txt
$(MAKE) tox PIP_CONSTRAINT=/code/upper-constraints-ussuri.txt

tox-yoga:
curl -L https://releases.openstack.org/constraints/upper/yoga -o upper-constraints-yoga.txt
sed -i '/etcd3gw/d' upper-constraints-yoga.txt
$(MAKE) tox PIP_CONSTRAINT=/code/upper-constraints-yoga.txt
2 changes: 1 addition & 1 deletion networking-calico/devstack/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ disable_service horizon
LOGFILE=stack.log
LOG_COLOR=False
TEMPEST_BRANCH=29.0.0
TEMPEST_BRANCH=29.1.0
# We commonly hit GnuTLS errors when git cloning OpenStack repos, for example:
# Cloning into 'devstack'...
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,11 @@
from keystoneauth1 import session
from keystoneclient.v3.client import Client as KeystoneClient

# Register [AGENT] options, which we need in order to successfully use
# PluginReportStateAPI.
from neutron.conf.agent import common as config
config.register_agent_state_opts_helper(cfg.CONF)

LOG = log.getLogger(__name__)

calico_opts = [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@
sys.modules['neutron.agent.rpc'] = m_neutron.agent.rpc
sys.modules['neutron.common'] = m_neutron.common
sys.modules['neutron.common.exceptions'] = m_neutron.common.exceptions
sys.modules['neutron.conf'] = m_neutron.conf
sys.modules['neutron.conf.agent'] = m_neutron.conf.agent
sys.modules['neutron.db'] = m_neutron.db
sys.modules['neutron.db.models'] = m_neutron.db.models
sys.modules['neutron.db.models.l3'] = m_neutron.db.models.l3
Expand Down
8 changes: 4 additions & 4 deletions networking-calico/test-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# of appearance. Changing the order has an impact on the overall integration
# process, which may cause wedges in the gate later.

setuptools!=24.0.0,!=34.0.0,!=34.0.1,!=34.0.2,!=34.0.3,!=34.1.0,!=34.1.1,!=34.2.0,!=34.3.0,!=34.3.1,!=34.3.2,!=36.2.0,>=21.0.0,<60.0.0 # PSF/ZPL
setuptools # PSF/ZPL

hacking<0.11,>=0.10.0

Expand All @@ -16,7 +16,7 @@ testrepository>=0.0.18 # Apache-2.0/BSD
testscenarios>=0.4 # Apache-2.0/BSD
testtools>=2.2.0 # MIT

neutron>=16,<17
neutron-lib==2.3.0
neutron
neutron-lib
mock>=3.0.0 # BSD
pyroute2<0.6.0 # Apache v2
pyroute2 # Apache v2
4 changes: 3 additions & 1 deletion networking-calico/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,12 @@ skipsdist = True

[testenv]
usedevelop = True
passenv =
HOME
PIP_CONSTRAINT
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning,ignore::DeprecationWarning:distutils,ignore::DeprecationWarning:site,ignore:Using or importing the ABCs,ignore:dns.hash module,ignore:Please provide `is_available
PIP_CONSTRAINT={toxinidir}/upper-constraints.txt
deps = -r{toxinidir}/test-requirements.txt
commands =
pip install -q -e "git+https://opendev.org/openstack/etcd3gw.git@1.0.1#egg=etcd3gw"
Expand Down

0 comments on commit 286ff5d

Please sign in to comment.