Migrate to charmhub
Change-Id: I8b998968aecf8f6d2485d4f5153211ceeac81b27
This commit is contained in:
parent
3a23930bb6
commit
011733c97f
@ -1,2 +1,7 @@
|
||||
# NOTES(lourot):
|
||||
# * We don't install charmcraft via pip anymore because it anyway spins up a
|
||||
# container and scp the system's charmcraft snap inside it. So the charmcraft
|
||||
# snap is necessary on the system anyway.
|
||||
# * `tox -e build` successfully validated with charmcraft 1.2.1
|
||||
|
||||
cffi==1.14.6; python_version < '3.6' # cffi 1.15.0 drops support for py35.
|
||||
git+https://github.com/canonical/charmcraft.git@0.10.2#egg=charmcraft
|
||||
|
27
charmcraft.yaml
Normal file
27
charmcraft.yaml
Normal file
@ -0,0 +1,27 @@
|
||||
type: charm
|
||||
|
||||
parts:
|
||||
charm:
|
||||
after:
|
||||
- update-certificates
|
||||
charm-python-packages:
|
||||
# NOTE(lourot): see
|
||||
# * https://github.com/canonical/charmcraft/issues/551
|
||||
# * https://github.com/canonical/charmcraft/issues/632
|
||||
- setuptools < 58
|
||||
build-packages:
|
||||
- git
|
||||
|
||||
update-certificates:
|
||||
plugin: nil
|
||||
# See https://github.com/canonical/charmcraft/issues/658
|
||||
override-build: |
|
||||
apt update
|
||||
apt install -y ca-certificates
|
||||
update-ca-certificates
|
||||
|
||||
bases:
|
||||
- name: ubuntu
|
||||
channel: "20.04"
|
||||
architectures:
|
||||
- amd64
|
20
osci.yaml
20
osci.yaml
@ -1,11 +1,10 @@
|
||||
- project:
|
||||
templates:
|
||||
- charm-yoga-unit-jobs
|
||||
- charm-unit-jobs-py38
|
||||
- charm-unit-jobs-py39
|
||||
check:
|
||||
jobs:
|
||||
- bionic-octopus
|
||||
- focal-octopus
|
||||
- hirsute-pacific
|
||||
vars:
|
||||
needs_charm_build: true
|
||||
charm_build_name: ceph-dashboard
|
||||
@ -14,22 +13,9 @@
|
||||
name: focal-octopus
|
||||
parent: func-target
|
||||
dependencies:
|
||||
- charm-build
|
||||
- osci-lint
|
||||
- tox-py36
|
||||
- tox-py38
|
||||
- tox-py39
|
||||
vars:
|
||||
tox_extra_args: focal
|
||||
- job:
|
||||
name: bionic-octopus
|
||||
parent: func-target
|
||||
dependencies: &smoke-jobs
|
||||
- focal-octopus
|
||||
vars:
|
||||
tox_extra_args: bionic-octopus
|
||||
- job:
|
||||
name: hirsute-pacific
|
||||
parent: func-target
|
||||
dependencies: *smoke-jobs
|
||||
vars:
|
||||
tox_extra_args: hirsute
|
||||
|
13
rename.sh
Executable file
13
rename.sh
Executable file
@ -0,0 +1,13 @@
|
||||
#!/bin/bash
|
||||
charm=$(grep "charm_build_name" osci.yaml | awk '{print $2}')
|
||||
echo "renaming ${charm}_*.charm to ${charm}.charm"
|
||||
echo -n "pwd: "
|
||||
pwd
|
||||
ls -al
|
||||
echo "Removing bad downloaded charm maybe?"
|
||||
if [[ -e "${charm}.charm" ]];
|
||||
then
|
||||
rm "${charm}.charm"
|
||||
fi
|
||||
echo "Renaming charm here."
|
||||
mv ${charm}_*.charm ${charm}.charm
|
19
tests/README.md
Normal file
19
tests/README.md
Normal file
@ -0,0 +1,19 @@
|
||||
# Overview
|
||||
|
||||
This directory provides Zaza test definitions and bundles to verify basic
|
||||
deployment functionality from the perspective of this charm, its requirements
|
||||
and its features, as exercised in a subset of the full OpenStack deployment
|
||||
test bundle topology.
|
||||
|
||||
Run the smoke tests with:
|
||||
|
||||
```bash
|
||||
cd ../
|
||||
tox -e build
|
||||
cd tests/
|
||||
tox -e func-smoke
|
||||
```
|
||||
|
||||
For full details on functional testing of OpenStack charms please refer to
|
||||
the [functional testing](https://docs.openstack.org/charm-guide/latest/reference/testing.html#functional-testing)
|
||||
section of the OpenStack Charm Guide.
|
@ -1,101 +0,0 @@
|
||||
local_overlay_enabled: False
|
||||
series: bionic
|
||||
applications:
|
||||
percona-cluster:
|
||||
charm: cs:~openstack-charmers-next/percona-cluster
|
||||
num_units: 1
|
||||
options:
|
||||
dataset-size: 25%
|
||||
max-connections: 1000
|
||||
source: cloud:bionic-ussuri
|
||||
ceph-osd:
|
||||
charm: cs:~openstack-charmers-next/ceph-osd
|
||||
num_units: 6
|
||||
storage:
|
||||
osd-devices: 'cinder,10G'
|
||||
options:
|
||||
osd-devices: '/dev/test-non-existent'
|
||||
source: cloud:bionic-ussuri
|
||||
ceph-mon:
|
||||
charm: cs:~openstack-charmers-next/ceph-mon
|
||||
num_units: 3
|
||||
options:
|
||||
monitor-count: '3'
|
||||
source: cloud:bionic-ussuri
|
||||
vault:
|
||||
num_units: 1
|
||||
charm: cs:~openstack-charmers-next/vault
|
||||
ceph-dashboard:
|
||||
charm: ../../ceph-dashboard.charm
|
||||
options:
|
||||
public-hostname: 'ceph-dashboard.zaza.local'
|
||||
prometheus:
|
||||
charm: cs:prometheus2
|
||||
num_units: 1
|
||||
grafana:
|
||||
# SSL and allow_embedding are not released into cs:grafana yet, due
|
||||
# Octrober 2021
|
||||
charm: cs:~llama-charmers-next/grafana
|
||||
num_units: 1
|
||||
options:
|
||||
anonymous: True
|
||||
install_plugins: https://storage.googleapis.com/plugins-community/vonage-status-panel/release/1.0.11/vonage-status-panel-1.0.11.zip,https://storage.googleapis.com/plugins-community/grafana-piechart-panel/release/1.6.2/grafana-piechart-panel-1.6.2.zip
|
||||
install_method: snap
|
||||
allow_embedding: True
|
||||
telegraf:
|
||||
charm: telegraf
|
||||
channel: stable
|
||||
options:
|
||||
hostname: "{host}"
|
||||
prometheus-alertmanager:
|
||||
charm: cs:prometheus-alertmanager
|
||||
num_units: 1
|
||||
ceph-radosgw:
|
||||
charm: cs:~openstack-charmers-next/ceph-radosgw
|
||||
num_units: 3
|
||||
options:
|
||||
source: cloud:bionic-ussuri
|
||||
ceph-fs:
|
||||
charm: cs:~openstack-charmers-next/ceph-fs
|
||||
num_units: 1
|
||||
options:
|
||||
source: cloud:bionic-ussuri
|
||||
relations:
|
||||
- - 'ceph-osd:mon'
|
||||
- 'ceph-mon:osd'
|
||||
- - 'vault:shared-db'
|
||||
- 'percona-cluster:shared-db'
|
||||
- - 'ceph-dashboard:dashboard'
|
||||
- 'ceph-mon:dashboard'
|
||||
- - 'ceph-dashboard:certificates'
|
||||
- 'vault:certificates'
|
||||
- - 'ceph-mon:prometheus'
|
||||
- 'prometheus:target'
|
||||
- - 'grafana:grafana-source'
|
||||
- 'prometheus:grafana-source'
|
||||
- - 'grafana:certificates'
|
||||
- 'vault:certificates'
|
||||
- - 'ceph-osd:juju-info'
|
||||
- 'telegraf:juju-info'
|
||||
- - 'ceph-mon:juju-info'
|
||||
- 'telegraf:juju-info'
|
||||
- - 'telegraf:prometheus-client'
|
||||
- 'prometheus:target'
|
||||
- - 'telegraf:dashboards'
|
||||
- 'grafana:dashboards'
|
||||
- - 'ceph-dashboard:grafana-dashboard'
|
||||
- 'grafana:dashboards'
|
||||
- - 'ceph-dashboard:alertmanager-service'
|
||||
- 'prometheus-alertmanager:alertmanager-service'
|
||||
- - 'ceph-dashboard:prometheus'
|
||||
- 'prometheus:website'
|
||||
- - 'prometheus:alertmanager-service'
|
||||
- 'prometheus-alertmanager:alertmanager-service'
|
||||
- - 'ceph-radosgw:mon'
|
||||
- 'ceph-mon:radosgw'
|
||||
- - 'ceph-radosgw:certificates'
|
||||
- 'vault:certificates'
|
||||
- - 'ceph-dashboard:radosgw-dashboard'
|
||||
- 'ceph-radosgw:radosgw-user'
|
||||
- - 'ceph-mon:mds'
|
||||
- 'ceph-fs:ceph-mds'
|
@ -2,26 +2,31 @@ local_overlay_enabled: False
|
||||
series: focal
|
||||
applications:
|
||||
ceph-osd:
|
||||
charm: cs:~openstack-charmers-next/ceph-osd
|
||||
charm: ch:ceph-osd
|
||||
num_units: 6
|
||||
storage:
|
||||
osd-devices: 'cinder,10G'
|
||||
options:
|
||||
osd-devices: '/dev/test-non-existent'
|
||||
channel: latest/edge
|
||||
ceph-mon:
|
||||
charm: cs:~openstack-charmers-next/ceph-mon
|
||||
charm: ch:ceph-mon
|
||||
num_units: 3
|
||||
options:
|
||||
monitor-count: '3'
|
||||
channel: latest/edge
|
||||
vault:
|
||||
num_units: 1
|
||||
charm: cs:~openstack-charmers-next/vault
|
||||
charm: ch:vault
|
||||
channel: latest/edge
|
||||
mysql-innodb-cluster:
|
||||
charm: cs:~openstack-charmers-next/mysql-innodb-cluster
|
||||
charm: ch:mysql-innodb-cluster
|
||||
constraints: mem=3072M
|
||||
num_units: 3
|
||||
channel: latest/edge
|
||||
vault-mysql-router:
|
||||
charm: cs:~openstack-charmers-next/mysql-router
|
||||
charm: ch:mysql-router
|
||||
channel: latest/edge
|
||||
ceph-dashboard:
|
||||
charm: ../../ceph-dashboard.charm
|
||||
options:
|
||||
@ -32,7 +37,7 @@ applications:
|
||||
grafana:
|
||||
# SSL and allow_embedding are not released into cs:grafana yet, due
|
||||
# Octrober 2021
|
||||
charm: cs:~llama-charmers-next/grafana
|
||||
charm: ch:grafana
|
||||
num_units: 1
|
||||
options:
|
||||
anonymous: True
|
||||
@ -48,16 +53,19 @@ applications:
|
||||
charm: cs:prometheus-alertmanager
|
||||
num_units: 1
|
||||
ceph-radosgw:
|
||||
charm: cs:~openstack-charmers-next/ceph-radosgw
|
||||
charm: ch:ceph-radosgw
|
||||
num_units: 3
|
||||
channel: latest/edge
|
||||
ceph-fs:
|
||||
charm: cs:~openstack-charmers-next/ceph-fs
|
||||
charm: ch:ceph-fs
|
||||
num_units: 1
|
||||
channel: latest/edge
|
||||
ceph-iscsi:
|
||||
charm: cs:~openstack-charmers-next/ceph-iscsi
|
||||
charm: ch:ceph-iscsi
|
||||
num_units: 2
|
||||
options:
|
||||
gateway-metadata-pool: iscsi-foo-metadata
|
||||
channel: latest/edge
|
||||
relations:
|
||||
- - 'ceph-osd:mon'
|
||||
- 'ceph-mon:osd'
|
||||
|
@ -1,68 +0,0 @@
|
||||
local_overlay_enabled: False
|
||||
series: hirsute
|
||||
applications:
|
||||
ceph-osd:
|
||||
charm: cs:~openstack-charmers-next/ceph-osd
|
||||
num_units: 6
|
||||
storage:
|
||||
osd-devices: 'cinder,10G'
|
||||
options:
|
||||
osd-devices: '/dev/test-non-existent'
|
||||
ceph-mon:
|
||||
charm: cs:~openstack-charmers-next/ceph-mon
|
||||
num_units: 3
|
||||
options:
|
||||
monitor-count: '3'
|
||||
vault:
|
||||
num_units: 1
|
||||
charm: cs:~openstack-charmers-next/vault
|
||||
mysql-innodb-cluster:
|
||||
charm: cs:~openstack-charmers-next/mysql-innodb-cluster
|
||||
constraints: mem=3072M
|
||||
num_units: 3
|
||||
vault-mysql-router:
|
||||
charm: cs:~openstack-charmers-next/mysql-router
|
||||
ceph-dashboard:
|
||||
charm: ../../ceph-dashboard.charm
|
||||
options:
|
||||
public-hostname: 'ceph-dashboard.zaza.local'
|
||||
ceph-radosgw-east:
|
||||
charm: cs:~openstack-charmers-next/ceph-radosgw
|
||||
num_units: 3
|
||||
options:
|
||||
pool-prefix: east
|
||||
region: east
|
||||
ceph-radosgw-west:
|
||||
charm: cs:~openstack-charmers-next/ceph-radosgw
|
||||
num_units: 3
|
||||
options:
|
||||
pool-prefix: west
|
||||
region: west
|
||||
ceph-fs:
|
||||
charm: cs:~openstack-charmers-next/ceph-fs
|
||||
num_units: 1
|
||||
relations:
|
||||
- - 'ceph-osd:mon'
|
||||
- 'ceph-mon:osd'
|
||||
- - 'vault:shared-db'
|
||||
- 'vault-mysql-router:shared-db'
|
||||
- - 'vault-mysql-router:db-router'
|
||||
- 'mysql-innodb-cluster:db-router'
|
||||
- - 'ceph-dashboard:dashboard'
|
||||
- 'ceph-mon:dashboard'
|
||||
- - 'ceph-dashboard:certificates'
|
||||
- 'vault:certificates'
|
||||
- - 'ceph-radosgw-east:mon'
|
||||
- 'ceph-mon:radosgw'
|
||||
- - 'ceph-radosgw-east:certificates'
|
||||
- 'vault:certificates'
|
||||
- - 'ceph-dashboard:radosgw-dashboard'
|
||||
- 'ceph-radosgw-east:radosgw-user'
|
||||
- - 'ceph-radosgw-west:mon'
|
||||
- 'ceph-mon:radosgw'
|
||||
- - 'ceph-radosgw-west:certificates'
|
||||
- 'vault:certificates'
|
||||
- - 'ceph-dashboard:radosgw-dashboard'
|
||||
- 'ceph-radosgw-west:radosgw-user'
|
||||
- - 'ceph-mon:mds'
|
||||
- 'ceph-fs:ceph-mds'
|
@ -1,5 +0,0 @@
|
||||
applications:
|
||||
grafana:
|
||||
options:
|
||||
http_proxy: '{{ TEST_HTTP_PROXY }}'
|
||||
install_plugins: {{ TEST_GRAFANA_PLUGIN_VONAGE_URL }},{{ TEST_GRAFANA_PLUGIN_PIECHART_URL }}
|
@ -1,8 +1,6 @@
|
||||
charm_name: ceph-dasboard
|
||||
gate_bundles:
|
||||
- focal
|
||||
- bionic-octopus
|
||||
- hirsute
|
||||
smoke_bundles:
|
||||
- focal
|
||||
configure:
|
||||
@ -28,6 +26,3 @@ target_deploy_status:
|
||||
telegraf:
|
||||
workload-status: active
|
||||
workload-status-message-prefix: Monitoring
|
||||
tests_options:
|
||||
force_deploy:
|
||||
- hirsute
|
||||
|
11
tox.ini
11
tox.ini
@ -15,8 +15,12 @@ skip_missing_interpreters = False
|
||||
# * It is also necessary to pin virtualenv as a newer virtualenv would still
|
||||
# lead to fetching the latest pip in the func* tox targets, see
|
||||
# https://stackoverflow.com/a/38133283
|
||||
# * It is necessary to declare setuptools as a dependency otherwise tox will
|
||||
# fail very early at not being able to load it. The version pinning is in
|
||||
# line with `pip.sh`.
|
||||
requires = pip < 20.3
|
||||
virtualenv < 20.0
|
||||
setuptools < 50.0.0
|
||||
# NOTE: https://wiki.canonical.com/engineering/OpenStack/InstallLatestToxOnOsci
|
||||
minversion = 3.2.0
|
||||
|
||||
@ -27,11 +31,12 @@ setenv = VIRTUAL_ENV={envdir}
|
||||
install_command =
|
||||
pip install {opts} {packages}
|
||||
commands = stestr run --slowest {posargs}
|
||||
whitelist_externals =
|
||||
allowlist_externals =
|
||||
git
|
||||
add-to-archive.py
|
||||
bash
|
||||
charmcraft
|
||||
rename.sh
|
||||
ls
|
||||
pwd
|
||||
passenv = HOME TERM CS_* OS_* TEST_*
|
||||
@ -109,7 +114,9 @@ commands = {posargs}
|
||||
basepython = python3
|
||||
deps = -r{toxinidir}/build-requirements.txt
|
||||
commands =
|
||||
charmcraft build
|
||||
charmcraft clean
|
||||
charmcraft -v build
|
||||
{toxinidir}/rename.sh
|
||||
|
||||
[testenv:func-noop]
|
||||
basepython = python3
|
||||
|
Loading…
Reference in New Issue
Block a user