Optima uses bill data to provide an accurate view of your costs across accounts and services. This data is consumed by the Optima platform and made available for pre-built and ad-hoc analyses. In order to gather the cost information, certain configuration steps must be performed with specific data and credentials being shared with Optima.
This page describes the configuration and input information needed to connect Google billing data to Optima using BigQuery billing exports.
For instructions on using Optima to add or update billing information, see the billing information guide. For instructions on connecting your cloud accounts to the platform for management purposes, see the cloud account management guide
This page walks you through the steps to connect your Google cloud billing data to RightScale for cost reporting purposes.
The following steps must be completed in order for RightScale to provide insight on your Google cloud bill:
Each of the steps above is explained in detail on this page.
Enable Billing Data Export to BigQuery in GCE
RightScale consumes the billing data via the BigQuery export method in Google. This can be enabled in GCE for each Billing Account and will contain data for all projects in that Billing Acccount.
RightScale uses BigQuery billing data as the source for billing information because the data is more complete (per Google). The estimated cost for BigQuery for billing purposes is no more than $100/yr for extremely large usage amounts (lesser usage will incur less cost). In some cases, the cost will be $0 as the entire usage will fall in the free tier of BigQuery.
If you have already configured billing export to BigQuery, please ensure you have the
Dataset ID and
Project that contains the dataset, and proceed to the next step.
If you need to configure data export to BigQuery, please follow the instructions provided by Google for your Google billing accounts.
Take note of the
Dataset ID when you create the dataset as well as the
Project in which the dataset exists.
Note that the Dataset ID is sometimes shown prepended with the project ID. For example,
project_id:dataset_id. In this case, please ensure you submit only the Dataset ID when registering your bill.
Allow RightScale to access the BigQuery dataset using a Service Account
Once your billing data is being exported to BigQuery, RightScale needs access to the BigQuery dataset to read the data. The RightScale platform uses a Google Service Account to gain access to the BigQuery dataset.
Once you have determined the service account you would like to use, the following steps must be completed:
Grant project-level IAM roles
The first step is to grant the service account the roles necessary to interact with BigQuery within the project.
- In Google Cloud Platform, navigate to the IAM menu
- Ensure the selected project is the on that contains the billing BigQuery dataset
- Click on the Add icon at the top
- Enter the service account ID
- Select the
BigQuery Data Viewerand
BigQuery Job Userroles
- Data Viewer - required to read data from the specified dataset
- Job User - needed to create query jobs from which results can be read (currently 2 jobs per day are created)
Share the dataset with the service account
Additionally, the BigQuery dataset must explicitly be shared with the service account.
- In Google Cloud Platform, navigate to BigQuery
- Locate the dataset that contains your billing data and
hoveryour mouse on the right to expose the dropdown menu
In the dropdown menu, selet
Towards the bottom, in the
Add peoplebox, enter the service account ID, ensure
Can viewis selected, and press Add
Submit the information
Follow the billing configuration guide to submit the above information to Optima