Add charmcraft 3 support

Update the charmcraft.yaml file to use base and platforms, only
allowing noble support.

- Update osci.yaml to use the charmcraft 3.x/beta
- Drop setuptools pinning in [test-]requirements.txt
- Add noble/oracular to charmhelpers
- Drop non-noble tests

Change-Id: Ie56db213b6cea6a266916b3b968a983f2f74c3ea
This commit is contained in:
Billy Olsen
2024-06-20 20:27:36 -07:00
committed by Billy Olsen
parent 253c24011d
commit f7a629cb0b
8 changed files with 34 additions and 135 deletions

View File

@@ -4,84 +4,33 @@ parts:
charm:
plugin: reactive
reactive-charm-build-arguments:
- --binary-wheels-from-source
- --verbose
- --binary-wheels-from-source
- --verbose
build-packages:
- tox
- git
- python3-dev
- libffi-dev
- libmysqlclient-dev
- pkg-config
- tox
- git
- python3-dev
- libffi-dev
- libmysqlclient-dev
- pkg-config
source: src/
build-snaps:
- charm/latest/stable
- charm/latest/edge
build-environment:
- CHARM_INTERFACES_DIR: $CRAFT_PROJECT_DIR/interfaces/
- CHARM_LAYERS_DIR: $CRAFT_PROJECT_DIR/layers/
- CHARM_INTERFACES_DIR: $CRAFT_PROJECT_DIR/interfaces/
- CHARM_LAYERS_DIR: $CRAFT_PROJECT_DIR/layers/
bases:
- build-on:
- name: ubuntu
channel: "20.04"
architectures: [amd64]
run-on:
- name: ubuntu
channel: "20.04"
architectures: [amd64]
- build-on:
- name: ubuntu
channel: "20.04"
architectures: [s390x]
run-on:
- name: ubuntu
channel: "20.04"
architectures: [s390x]
- build-on:
- name: ubuntu
channel: "20.04"
architectures: [ppc64el]
run-on:
- name: ubuntu
channel: "20.04"
architectures: [ppc64el]
- build-on:
- name: ubuntu
channel: "20.04"
architectures: [arm64]
run-on:
- name: ubuntu
channel: "20.04"
architectures: [arm64]
- build-on:
- name: ubuntu
channel: "22.04"
architectures: [amd64]
run-on:
- name: ubuntu
channel: "22.04"
architectures: [amd64]
- build-on:
- name: ubuntu
channel: "22.04"
architectures: [s390x]
run-on:
- name: ubuntu
channel: "22.04"
architectures: [s390x]
- build-on:
- name: ubuntu
channel: "22.04"
architectures: [ppc64el]
run-on:
- name: ubuntu
channel: "22.04"
architectures: [ppc64el]
- build-on:
- name: ubuntu
channel: "22.04"
architectures: [arm64]
run-on:
- name: ubuntu
channel: "22.04"
architectures: [arm64]
base: ubuntu@24.04
platforms:
amd64:
build-on: amd64
build-for: amd64
arm64:
build-on: arm64
build-for: arm64
ppc64el:
build-on: ppc64el
build-for: ppc64el
s390x:
build-on: s390x
build-for: s390x

View File

@@ -1,13 +1,11 @@
- project:
templates:
- charm-unit-jobs-py38
- charm-unit-jobs-py310
check:
jobs:
- focal
- jammy
- noble
vars:
needs_charm_build: true
charm_build_name: mysql-innodb-cluster
build_type: charmcraft
charmcraft_channel: "2.x/stable"
charmcraft_channel: "3.x/beta"

View File

@@ -6,7 +6,6 @@
# NOTE(lourot): This might look like a duplication of test-requirements.txt but
# some tox targets use only test-requirements.txt whereas charm-build uses only
# requirements.txt
setuptools<50.0.0 # https://github.com/pypa/setuptools/commit/04e3df22df840c6bb244e9b27bc56750c44b7c85
# Build requirements
cffi==1.14.6; python_version < '3.6' # cffi 1.15.0 drops support for py35.

View File

@@ -1,47 +0,0 @@
local_overlay_enabled: True
series: focal
applications:
keystone-mysql-router:
charm: ch:mysql-router
channel: latest/edge
vault-mysql-router:
charm: ch:mysql-router
channel: latest/edge
mysql-innodb-cluster:
series: focal
charm: ../../../mysql-innodb-cluster_ubuntu-20.04-amd64.charm
num_units: 3
options:
prometheus-exporter-snap-channel: edge
keystone:
charm: ch:keystone
num_units: 3
channel: yoga/edge
keystone-hacluster:
charm: ch:hacluster
channel: 2.0.3/edge
vault:
charm: ch:vault
num_units: 1
channel: 1.7/edge
prometheus2:
charm: ch:prometheus2
num_units: 1
relations:
- - vault:certificates
- mysql-innodb-cluster:certificates
- - vault:certificates
- keystone:certificates
- - keystone:shared-db
- keystone-mysql-router:shared-db
- - vault:shared-db
- vault-mysql-router:shared-db
- - keystone-mysql-router:db-router
- mysql-innodb-cluster:db-router
- - vault-mysql-router:db-router
- mysql-innodb-cluster:db-router
- - prometheus2:target
- mysql-innodb-cluster:prometheus
- - "keystone:ha"
- "keystone-hacluster:ha"

View File

@@ -1,6 +1,6 @@
local_overlay_enabled: True
series: jammy
series: noble
applications:
keystone-mysql-router:
charm: ch:mysql-router
@@ -9,7 +9,7 @@ applications:
charm: ch:mysql-router
channel: latest/edge
mysql-innodb-cluster:
charm: ../../../mysql-innodb-cluster_ubuntu-22.04-amd64.charm
charm: ../../../mysql-innodb-cluster_amd64.charm
num_units: 3
options:
prometheus-exporter-snap-channel: edge

View File

@@ -19,14 +19,14 @@ tests:
- zaza.openstack.charm_tests.mysql.test_prometheus_mysql_exporter.PrometheusMySQLExporterTest
gate_bundles:
- scale_in_out: focal
- scale_in_out: jammy
- scale_in_out: noble
- scale_in_out: noble
smoke_bundles:
- focal
- noble
dev_bundles:
- scale_in_out: jammy
- scale_in_out: noble
tests_options:
force_deploy: []

View File

@@ -3,5 +3,6 @@ psutil
poetry-core
tenacity<8.0.0
git+https://github.com/wolsen/charms.reactive.git@fix-entry-points#egg=charms.reactive
git+https://github.com/openstack/charms.openstack.git#egg=charms.openstack
git+https://github.com/juju/charm-helpers.git#egg=charmhelpers

View File

@@ -5,7 +5,6 @@
#
pyparsing<3.0.0 # aodhclient is pinned in zaza and needs pyparsing < 3.0.0, but cffi also needs it, so pin here.
cffi==1.14.6; python_version < '3.6' # cffi 1.15.0 drops support for py35.
setuptools<50.0.0 # https://github.com/pypa/setuptools/commit/04e3df22df840c6bb244e9b27bc56750c44b7c85
stestr>=2.2.0