diff options
| author | Zuul <zuul@review.opendev.org> | 2025-09-15 10:34:24 +0000 |
|---|---|---|
| committer | Gerrit Code Review <review@openstack.org> | 2025-09-15 10:34:24 +0000 |
| commit | 6f996afe3f644dc5dca8f3dae1aacaa73cd61f24 (patch) | |
| tree | 7024c40040dd42c60d48b17263c0bf319ea4ffd0 /tests | |
| parent | 16731f0588962e1d064d09fe686a2bde6f383334 (diff) | |
| parent | 0c60010bd5e11de9dfd398e9f534479601992a7e (diff) | |
| download | kolla-ansible-6f996afe3f644dc5dca8f3dae1aacaa73cd61f24.tar.gz kolla-ansible-6f996afe3f644dc5dca8f3dae1aacaa73cd61f24.zip | |
Merge "CI: Add telemetry scenario"
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/run.yml | 7 | ||||
| -rw-r--r-- | tests/templates/globals-default.j2 | 6 | ||||
| -rwxr-xr-x | tests/test-telemetry.sh | 42 |
3 files changed, 55 insertions, 0 deletions
diff --git a/tests/run.yml b/tests/run.yml index 99f110e31..d03187b95 100644 --- a/tests/run.yml +++ b/tests/run.yml @@ -571,6 +571,13 @@ chdir: "{{ kolla_ansible_src_dir }}" when: scenario == "skyline-sso" + - name: Run test-telemetry.sh script + script: + cmd: test-telemetry.sh + executable: /bin/bash + chdir: "{{ kolla_ansible_src_dir }}" + when: scenario == "telemetry" + - name: Run test-container-engine-migration.sh script script: cmd: test-container-engine-migration.sh diff --git a/tests/templates/globals-default.j2 b/tests/templates/globals-default.j2 index fe7950e65..77b02f4b6 100644 --- a/tests/templates/globals-default.j2 +++ b/tests/templates/globals-default.j2 @@ -278,5 +278,11 @@ enable_skyline: "yes" skyline_enable_sso: "yes" {% endif %} +{% if scenario == "telemetry" %} +enable_aodh: "yes" +enable_ceilometer: "yes" +enable_gnocchi: "yes" +{% endif %} + mariadb_monitor_read_only_interval: "30000" mariadb_monitor_galera_healthcheck_timeout: "30000" diff --git a/tests/test-telemetry.sh b/tests/test-telemetry.sh new file mode 100755 index 000000000..91b5f6c32 --- /dev/null +++ b/tests/test-telemetry.sh @@ -0,0 +1,42 @@ +#!/bin/bash + +set -o xtrace +set -o errexit +set -o pipefail + +# Enable unbuffered output +export PYTHONUNBUFFERED=1 + +function test_aodh { + echo "TESTING: Aodh" + openstack alarm list + echo "SUCCESS: Aodh" +} + +function test_gnocchi { + echo "TESTING: Gnocchi" + openstack metric list + openstack metric resource list + echo "SUCCESS: Gnocchi" +} + +function test_telemetry_scenario_logged { + . /etc/kolla/admin-openrc.sh + . ~/openstackclient-venv/bin/activate + test_aodh + test_gnocchi +} + +function test_telemetry_scenario { + echo "Testing Telemetry" + test_telemetry_scenario_logged > /tmp/logs/ansible/test-telemetry-scenario 2>&1 + result=$? + if [[ $result != 0 ]]; then + echo "Testing Telemetry scenario failed. See ansible/test-telemetry-scenario for details" + else + echo "Successfully tested Telemetry scenario. See ansible/test-telemetry-scenario for details" + fi + return $result +} + +test_telemetry_scenario |
