@@ -23,16 +23,19 @@ Use Prometheus as the collector and fetcher backends, and Elasticsearch as the
2323storage backend. Note that this is patched in our fork of CloudKitty to also
2424work with OpenSearch. Proper support is still pending in Kolla-Ansible `here
2525<https://review.opendev.org/c/openstack/kolla-ansible/+/898555> `__. If you have
26- TLS enabled, you will also need to allow insecure connections for Prometheus
27- and Elasticsearch. Set the following in ``kolla/globals.yml ``:
26+ TLS enabled, you will also need to set the cafile for Prometheus and
27+ Elasticsearch. Set the following in ``kolla/globals.yml ``, and make sure that
28+ ``openstack_cacert `` is appropriately set as a Kayobe variable too. It defaults
29+ to ``openstack_cacert: "{{ lookup('env', 'OS_CACERT') }}" ``, but you may prefer
30+ to set the path explicitly.
2831
2932.. code-block :: console
3033
3134 cloudkitty_collector_backend: prometheus
3235 cloudkitty_fetcher_backend: prometheus
3336 cloudkitty_storage_backend: elasticsearch
34- cloudkitty_elasticsearch_insecure_connections: true
35- cloudkitty_prometheus_insecure_connections: true
37+ cloudkitty_prometheus_cafile: "{{ openstack_cacert }}"
38+ cloudkitty_elasticsearch_cafile: "{{ openstack_cacert }}"
3639
3740 The default collection period is one hour, which is likely too long for your
3841system. CloudKitty will charge for the entire period if any usage is seen
@@ -56,25 +59,25 @@ will track for flavors and volumes, set in
5659
5760 metrics:
5861 openstack_nova_server_status:
59- alt_name: instance
60- groupby:
62+ alt_name: instance
63+ groupby:
6164 - uuid
6265 - user_id
6366 - tenant_id
64- metadata:
67+ metadata:
6568 - flavor_id
6669 - name
67- mutate: MAP
68- mutate_map:
70+ mutate: MAP
71+ mutate_map:
6972 0.0: 1.0 # ACTIVE
7073 11.0: 1.0 # SHUTOFF
7174 12.0: 1.0 # SUSPENDED
7275 16.0: 1.0 # PAUSED
73- unit: instance
76+ unit: instance
7477 openstack_cinder_limits_volume_used_gb:
75- alt_name: storage
76- unit: GiB
77- groupby:
78+ alt_name: storage
79+ unit: GiB
80+ groupby:
7881 - tenant_id
7982
8083 TODO: Should we explain how to handle OpenStack exporter metrics relabelling,
0 commit comments