diff --git a/.gitignore b/.gitignore index 9b27813..31de773 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,4 @@ xenial/ .stestr __pycache__ func-results.json +*.charm diff --git a/charmcraft.yaml b/charmcraft.yaml index 2459a54..6703d0e 100644 --- a/charmcraft.yaml +++ b/charmcraft.yaml @@ -20,7 +20,15 @@ parts: cp -r $CHARMCRAFT_STAGE/* . bases: - - name: ubuntu - channel: "20.04" - architectures: - - amd64 + - build-on: + - name: ubuntu + channel: "20.04" + architectures: + - amd64 + run-on: + - name: ubuntu + channel: "20.04" + architectures: [amd64, s390x, ppc64el, arm64] + - name: ubuntu + channel: "22.04" + architectures: [amd64, s390x, ppc64el, arm64] diff --git a/osci.yaml b/osci.yaml index 66e10ca..e07d0b2 100644 --- a/osci.yaml +++ b/osci.yaml @@ -1,7 +1,7 @@ - project: templates: - charm-unit-jobs-py38 - - charm-unit-jobs-py39 + - charm-unit-jobs-py310 - charm-xena-functional-jobs - charm-yoga-functional-jobs vars: diff --git a/requirements.txt b/requirements.txt index a68620f..7755b95 100644 --- a/requirements.txt +++ b/requirements.txt @@ -8,9 +8,16 @@ # requirements.txt setuptools<50.0.0 # https://github.com/pypa/setuptools/commit/04e3df22df840c6bb244e9b27bc56750c44b7c85 +# NOTE: newer versions of cryptography require a Rust compiler to build, +# see +# * https://github.com/openstack-charmers/zaza/issues/421 +# * https://mail.python.org/pipermail/cryptography-dev/2021-January/001003.html +# +cryptography<3.4 + # Build requirements cffi==1.14.6; python_version < '3.6' # cffi 1.15.0 drops support for py35. -charm-tools==2.8.3 +git+https://github.com/juju/charm-tools#egg=charm-tools simplejson diff --git a/src/config.yaml b/src/config.yaml index 9681b63..cd3bb4a 100644 --- a/src/config.yaml +++ b/src/config.yaml @@ -1,6 +1,6 @@ options: openstack-origin: - default: distro + default: yoga type: string description: | Repository from which to install. May be one of the following: diff --git a/src/metadata.yaml b/src/metadata.yaml index 9115ec7..6cc7ab6 100644 --- a/src/metadata.yaml +++ b/src/metadata.yaml @@ -14,7 +14,7 @@ tags: - baremetal series: - focal -- impish +- jammy extra-bindings: deployment: cleaning: diff --git a/src/tests/bundles/focal-xena.yaml b/src/tests/bundles/focal-xena.yaml index 71774e2..679a05d 100644 --- a/src/tests/bundles/focal-xena.yaml +++ b/src/tests/bundles/focal-xena.yaml @@ -3,7 +3,7 @@ local_overlay_enabled: False options: source: &source cloud:focal-xena series: focal -local_overlay_enabled: false + relations: - - nova-ironic - ironic-api diff --git a/src/tests/bundles/focal-yoga.yaml b/src/tests/bundles/focal-yoga.yaml index e1292cc..88ca2e3 100644 --- a/src/tests/bundles/focal-yoga.yaml +++ b/src/tests/bundles/focal-yoga.yaml @@ -3,7 +3,6 @@ local_overlay_enabled: False options: source: &source cloud:focal-yoga series: focal -local_overlay_enabled: false relations: - - nova-ironic - ironic-api diff --git a/src/tests/bundles/impish-xena.yaml b/src/tests/bundles/impish-xena.yaml deleted file mode 100644 index 3ca9602..0000000 --- a/src/tests/bundles/impish-xena.yaml +++ /dev/null @@ -1,305 +0,0 @@ -local_overlay_enabled: False - -options: - source: &source distro -series: impish -local_overlay_enabled: false -relations: -- - nova-ironic - - ironic-api -- - ironic-conductor - - ironic-api -- - neutron-ironic-agent:identity-credentials - - keystone -- - neutron-ironic-agent - - neutron-api -- - ironic-api:amqp - - rabbitmq-server:amqp -- - ironic-api - - keystone -- - ironic-api:shared-db - - ironic-api-mysql-router:shared-db -- - ironic-conductor:amqp - - rabbitmq-server:amqp -- - ironic-conductor - - keystone -- - ironic-conductor:shared-db - - ironic-conductor-mysql-router:shared-db -- - nova-ironic:amqp - - rabbitmq-server:amqp -- - nova-ironic - - glance -- - nova-ironic - - keystone -- - nova-ironic - - nova-cloud-controller -- - neutron-gateway:amqp - - rabbitmq-server:amqp -- - keystone:shared-db - - keystone-mysql-router:shared-db -- - nova-cloud-controller:identity-service - - keystone:identity-service -- - glance:identity-service - - keystone:identity-service -- - neutron-api:identity-service - - keystone:identity-service -- - neutron-api:shared-db - - neutron-api-mysql-router:shared-db -- - neutron-api:amqp - - rabbitmq-server:amqp -- - neutron-gateway:neutron-plugin-api - - neutron-api:neutron-plugin-api -- - glance:shared-db - - glance-mysql-router:shared-db -- - glance:amqp - - rabbitmq-server:amqp -- - nova-cloud-controller:image-service - - glance:image-service -- - nova-cloud-controller:amqp - - rabbitmq-server:amqp -- - nova-cloud-controller:quantum-network-service - - neutron-gateway:quantum-network-service -- - nova-cloud-controller:shared-db - - nova-cloud-controller-mysql-router:shared-db -- - nova-cloud-controller:neutron-api - - neutron-api:neutron-api -- - cinder:image-service - - glance:image-service -- - cinder:amqp - - rabbitmq-server:amqp -- - cinder:identity-service - - keystone:identity-service -- - cinder:cinder-volume-service - - nova-cloud-controller:cinder-volume-service -- - cinder:shared-db - - cinder-mysql-router:shared-db -- - placement:shared-db - - placement-mysql-router:shared-db -- - placement - - keystone -- - placement - - nova-cloud-controller -- - ceph-mon:client - - nova-ironic:ceph -- - ceph-mon:client - - glance:ceph -- - ceph-radosgw:mon - - ceph-mon:radosgw -- - ceph-radosgw:identity-service - - keystone:identity-service -- - ceph-osd:mon - - ceph-mon:osd -- - ceph-radosgw:object-store - - glance -- - mysql-innodb-cluster:db-router - - nova-cloud-controller-mysql-router:db-router -- - mysql-innodb-cluster:db-router - - keystone-mysql-router:db-router -- - mysql-innodb-cluster:db-router - - glance-mysql-router:db-router -- - mysql-innodb-cluster:db-router - - neutron-api-mysql-router:db-router -- - mysql-innodb-cluster:db-router - - placement-mysql-router:db-router -- - mysql-innodb-cluster:db-router - - cinder-mysql-router:db-router -- - mysql-innodb-cluster:db-router - - ironic-api-mysql-router:db-router -- - mysql-innodb-cluster:db-router - - ironic-conductor-mysql-router:db-router -- - vault-mysql-router:db-router - - mysql-innodb-cluster:db-router -- - vault:shared-db - - vault-mysql-router:shared-db -- - vault:certificates - - ceph-radosgw -- - vault:certificates - - cinder -- - vault:certificates - - glance:certificates -- - vault:certificates - - keystone:certificates -- - vault:certificates - - neutron-api:certificates -- - vault:certificates - - nova-cloud-controller:certificates -- - vault:certificates - - placement:certificates -- - vault - - ironic-conductor -- - vault:certificates - - ironic-api:certificates -- - ironic-api - - hacluster-ironic -services: - nova-cloud-controller-mysql-router: - charm: ch:mysql-router - channel: latest/edge - keystone-mysql-router: - charm: ch:mysql-router - channel: latest/edge - glance-mysql-router: - charm: ch:mysql-router - channel: latest/edge - neutron-api-mysql-router: - charm: ch:mysql-router - channel: latest/edge - placement-mysql-router: - charm: ch:mysql-router - channel: latest/edge - vault-mysql-router: - charm: ch:mysql-router - channel: latest/edge - cinder-mysql-router: - charm: ch:mysql-router - channel: latest/edge - ironic-api-mysql-router: - charm: ch:mysql-router - channel: latest/edge - ironic-conductor-mysql-router: - charm: ch:mysql-router - channel: latest/edge - mysql-innodb-cluster: - charm: ch:mysql-innodb-cluster - num_units: 3 - constraints: mem=4G - options: - source: *source - channel: latest/edge - cinder: - charm: ch:cinder - num_units: 1 - constraints: mem=2G - options: - block-device: vdb - glance-api-version: 2 - openstack-origin: *source - worker-multiplier: 0.25 - storage: - block-devices: cinder,50G - channel: latest/edge - ceph-radosgw: - charm: ch:ceph-radosgw - num_units: 1 - constraints: mem=2G - options: - source: *source - namespace-tenants: True - channel: latest/edge - ceph-mon: - charm: ch:ceph-mon - num_units: 3 - constraints: mem=2G - options: - expected-osd-count: 3 - source: *source - channel: latest/edge - ceph-osd: - charm: ch:ceph-osd - num_units: 3 - constraints: mem=2G - options: - source: *source - storage: - osd-devices: 'cinder,30G' - channel: latest/edge - glance: - charm: ch:glance - num_units: 1 - constraints: mem=2G - options: - openstack-origin: *source - worker-multiplier: 0.25 - channel: latest/edge - keystone: - charm: ch:keystone - num_units: 1 - constraints: mem=2G - options: - openstack-origin: *source - worker-multiplier: 0.25 - channel: latest/edge - neutron-api: - charm: ch:neutron-api - num_units: 1 - constraints: mem=2G - options: - flat-network-providers: "physnet1" - neutron-security-groups: true - openstack-origin: *source - manage-neutron-plugin-legacy-mode: false - worker-multiplier: 0.25 - channel: latest/edge - neutron-gateway: - charm: ch:neutron-gateway - num_units: 1 - constraints: mem=2G - options: - openstack-origin: *source - enable-isolated-metadata: true - enable-metadata-network: true - bridge-mappings: physnet1:br-ex - channel: latest/edge - nova-cloud-controller: - charm: ch:nova-cloud-controller - num_units: 1 - constraints: mem=2G - options: - network-manager: Neutron - openstack-origin: *source - worker-multiplier: 0.25 - channel: latest/edge - nova-ironic: - charm: ch:nova-compute - num_units: 1 - constraints: mem=2G - options: - enable-live-migration: false - enable-resize: false - openstack-origin: *source - virt-type: ironic - channel: latest/edge - placement: - charm: ch:placement - num_units: 1 - constraints: mem=2G - options: - openstack-origin: *source - worker-multiplier: 0.25 - channel: latest/edge - rabbitmq-server: - charm: ch:rabbitmq-server - num_units: 1 - constraints: mem=2G - channel: latest/edge - hacluster-ironic: - charm: ch:hacluster - num_units: 0 - channel: latest/edge - ironic-api: - charm: ch:openstack-charmers-next-ironic-api - num_units: 3 - constraints: mem=2G - options: - openstack-origin: *source - channel: latest/edge - ironic-conductor: - charm: ../../../ironic-conductor.charm - num_units: 1 - constraints: mem=2G - options: - openstack-origin: *source - max-tftp-block-size: 1418 - disable-secure-erase: true - use-ipxe: true - enabled-network-interfaces: "flat, noop" - neutron-ironic-agent: - charm: ch:openstack-charmers-next-neutron-api-plugin-ironic - num_units: 0 - options: - openstack-origin: *source - channel: latest/edge - vault: - charm: ch:vault - num_units: 1 - channel: latest/edge diff --git a/src/tests/bundles/jammy-yoga.yaml b/src/tests/bundles/jammy-yoga.yaml index 9bb8039..021bd6e 100644 --- a/src/tests/bundles/jammy-yoga.yaml +++ b/src/tests/bundles/jammy-yoga.yaml @@ -3,7 +3,6 @@ local_overlay_enabled: False options: source: &source distro series: jammy -local_overlay_enabled: false relations: - - nova-ironic - ironic-api diff --git a/src/tests/bundles/overlays/bionic-train.yaml.j2 b/src/tests/bundles/overlays/bionic-train.yaml.j2 deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/bionic-train.yaml.j2 +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/bionic-ussuri.yaml.j2 b/src/tests/bundles/overlays/bionic-ussuri.yaml.j2 deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/bionic-ussuri.yaml.j2 +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/focal-ussuri.yaml.j2 b/src/tests/bundles/overlays/focal-ussuri.yaml.j2 deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/focal-ussuri.yaml.j2 +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/focal-victoria.yaml.j2 b/src/tests/bundles/overlays/focal-victoria.yaml.j2 deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/focal-victoria.yaml.j2 +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/focal-wallaby.yaml.j2 b/src/tests/bundles/overlays/focal-wallaby.yaml.j2 deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/focal-wallaby.yaml.j2 +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/focal-xena.yaml b/src/tests/bundles/overlays/focal-xena.yaml deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/focal-xena.yaml +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/hirsute-wallaby.yaml.j2 b/src/tests/bundles/overlays/hirsute-wallaby.yaml.j2 deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/hirsute-wallaby.yaml.j2 +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/impish-xena.yaml b/src/tests/bundles/overlays/impish-xena.yaml deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/impish-xena.yaml +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/src/tests/bundles/overlays/impish-xena.yaml.j2 b/src/tests/bundles/overlays/impish-xena.yaml.j2 deleted file mode 120000 index f07f22d..0000000 --- a/src/tests/bundles/overlays/impish-xena.yaml.j2 +++ /dev/null @@ -1 +0,0 @@ -ironic.j2 \ No newline at end of file diff --git a/tox.ini b/tox.ini index 2d60b8a..e22fe48 100644 --- a/tox.ini +++ b/tox.ini @@ -68,21 +68,11 @@ basepython = python3 deps = -r{toxinidir}/test-requirements.txt commands = stestr run --slowest {posargs} -[testenv:py35] -basepython = python3.5 -deps = -r{toxinidir}/test-requirements.txt -commands = stestr run --slowest {posargs} - [testenv:py36] basepython = python3.6 deps = -r{toxinidir}/test-requirements.txt commands = stestr run --slowest {posargs} -[testenv:py37] -basepython = python3.7 -deps = -r{toxinidir}/test-requirements.txt -commands = stestr run --slowest {posargs} - [testenv:py38] basepython = python3.8 deps = -r{toxinidir}/test-requirements.txt @@ -93,6 +83,11 @@ basepython = python3.9 deps = -r{toxinidir}/test-requirements.txt commands = stestr run --slowest {posargs} +[testenv:py310] +basepython = python3.10 +deps = -r{toxinidir}/test-requirements.txt +commands = stestr run --slowest {posargs} + [testenv:pep8] basepython = python3 deps = flake8==3.9.2