Skip to main content
Skip table of contents

Kubernetes Billing via OpenCost

OpenCost is an open-source cost monitoring tool designed for Kubernetes. This guide explains how to integrate Kubernetes Billing via OpenCost with Cloudaware.

Overview

Cloud billing reports from major providers often lack the granularity needed to understand costs at the level of individual Kubernetes cluster components. Tools such as OpenCost and Parquet Exporter provide this level of detail, enabling more accurate cost tracking and attribution within the cluster.

OpenCost collects in-cluster resource-usage data and calculates the associated costs. The Parquet Exporter plugin exports this usage and cost data to cloud storage on a daily schedule. Cloudaware then retrieves and imports the exported data for further processing and analysis.

Summary

To integrate Kubernetes Billing with Cloudaware:

  1. Add the cloud account to Cloudaware.

  2. Configure OpenCost for the Kubernetes cluster.

  3. Set up the integration in Cloudaware.

See the setup guidelines below for details.

Add cloud account

To add a cloud account to Cloudaware, use the following start guides:

Configure OpenCost

Сonfigure OpenCost and the Parquet Exporter for your cluster:

Set up Kubernetes billing in Cloudaware

Once the export files are available in the designated buckets, configure the Kubernetes Billing integration in Cloudaware:

  1. Log in to Cloudaware → Admin.

    Kubernetes Billing via OpenCost - admin.png

  2. Find Kubernetes Billing in Billing integrations. Click +ADD.

    Kubernetes Billing via OpenCost - add integration.png

  3. Select the cloud provider* and fill out the form:

    Kubernetes Billing via OpenCost - integration details.png


    For AWS:
    Account – select the AWS account containing the S3 bucket with the Parquet exports
    Region – enter the S3 bucket region
    Bucket – enter the S3 bucket name
    Cluster Prefix – enter the OpenCost billing file path ending with kubernetes_clusters (the part preceding the cluster ARN), as configured during the Parquet Exporter deployment. See Step 5 in the OpenCost Deployment for AWS guide.

    For Azure:
    Active Directory – select the Active Directory associated with the storage account containing the Parquet exports
    Storage Account – enter the storage account name
    Container – enter the blob container name
    Cluster Prefix – enter the OpenCost billing file path ending with kubernetes_clusters (the part preceding the cluster ID), as configured during the Parquet Exporter deployment. See Step 6 in the OpenCost Deployment for Microsoft Azure guide.

    For Google:
    Service Account – select the Google service account associated with the storage bucket containing the Parquet exports
    Bucket – enter the storage bucket name
    Cluster Prefix – enter the OpenCost billing file path ending with kubernetes_clusters (the part preceding the cluster ID), as configured during the Parquet Exporter deployment. See Step 6 in the OpenCost Deployment for Google Cloud guide.

    Click CHECK to validate the connection. Once validation succeeds, click SAVE.

*For multi-cloud environments, configure a separate Kubernetes Billing integration for each cloud provider.

  1. Check the integration status. A green light in the ‘Status’ column indicates successful configuration. If the light is red, contact support@cloudaware.com.

    Kubernetes Billing via OpenCost - integration status.png
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.