grafana / cloudcost-exporter

Prometheus Exporter for Cloud Provider agnostic cost metrics
Apache License 2.0
66 stars 4 forks source link

fix(persistentvolues): Properly handle searching for storage classes #138

Closed Pokom closed 7 months ago

Pokom commented 7 months ago

This adds tests to validate that regional sku's were overwriting standard, ssd, and balanced disks costs which effectively was doubling the cost per persistent volume.

The fix is to check if the description starts with the storage class as opposed to simply checking if it Contains. Typically what you would see is a Description like Regional Storage backed PD Capacity which would return true when checking if it contains Storage backed PD Capacity.