AKS cost allocation
Cost allocation for AKS is complex, and Azure currently does not support detailed cost allocation (by namespace, node, container, deployment, etc.). Due to this, we will be using Kubecost to get the cost allocation capability.
First, we will configure Kubecost to our existing AKS cluster, and then we will configure the Azure billing export so that Kubecost can read the billing data and learn about out-of-cluster costs, as well as our rates and discounts.
To configure Kubecost, follow these steps:
- Open the Microsoft Edge browser.
- Navigate to https://portal.azure.com and sign in with your organization's account.
- In the top search bar, search for
Kubernetes Services
and select the highlighted service. - From the list of AKS clusters, click on the cluster you want to install Kubecost.
- Next, click on Connect to get the instructions to connect to your AKS cluster.
Figure 10.3 – Connecting to the AKS...