To create a budget for a Cloud Billing account, we need to have billing.budgets.create permissions. To view all budgets, billing.budgets.get and billing.budgets.list IAM permissions are required.
One way of assigning this permission could be the IAM role assignment of Billing Account Administrator or Billing Account Costs Manager.
Let’s create our first budget in Google Cloud Console:
- Navigate to the Billing section of Cloud Console.
- Choose Budgets & alerts from the Cost management section.
- Click the CREATE BUDGET button:
Figure 3.21 – Initial budget creation dialog
- We need to provide a budget name, choose a time range (a Monthly, Quarterly, Yearly, or Custom range), specify how many projects to include (one, more, or all), and select the desired services:
Figure 3.22 – Scoping the budget
- In the Amount section, choose Specified amount if your budget should be compared against it. Choose Last month’s spend if your budget should be dynamically compared to the last calendar period’s spend:
Figure 3.23 – Selection of the type of budget and the amount
- In the last section of budget creation, we need to enter threshold rules. We can add more thresholds if we want more granular notifications. By default, we have three points, but more can be added:
Figure 3.24 – Final budget creation page
- To complete the budget creation, we need to select one of the notification channels. It can be an email alert to billing administrators and users, linking the monitoring email notification channel to the budget, or connecting the Pub/Sub topic to the budget once the selected budget creation is completed.
- It is important to mention – budget creation doesn’t stop the usage of your resources or block the creation of new ones. Once you reach 100% of your budget, you can still create new cloud resources, but you will be charged for them.
Budgets can be edited and deleted, but the essential task is to create one and not miss the notifications when exceeding the configured thresholds. To learn more about Google Cloud budgets, visit this link: https://cloud.google.com/billing/docs/how-to/budgets-notification-recipients.
Viewing billing and cloud usage
Billing is configured and we created alerts so we are well prepared to consume Google Cloud resources. The Billing section allows us to view detailed reports and break down costs at the project or service level:
Figure 3.25 – Sample last month’s report view
You see an example of a monthly report for our account in the preceding figure. On the right-hand side, we can filter the views by projects, folders and organizations, services, and more:
Figure 3.26 – Cost table breakdown filtered on the project level
We can view the project ID, SKU, and SKU description information in this detailed view.