Chapter 3. Integrate your AWS account without data filtering
Create an unfiltered AWS cloud integration and configure your AWS account to give cost management access to your AWS Cost and Usage Reports.
The service account used to upload data must be a member of a user group that has the cost management:settings:write permission. When configuring this in the Red Hat Hybrid Cloud Console, ensure that the group’s assigned role includes the cost-management application and the settings resource type with write operations enabled. This is required to access the Ingress Reports API for data uploads.
You must have a Red Hat account with Cloud Administrator permissions.
- If you want to create a filtered AWS integration, do not complete the following steps. Instead, go to Integrate your AWS account with data filtering for privacy.
- AWS is a third-party product and its UI and documentation can change. The instructions for configuring third-party integrations are correct at the time of publishing. For the most up-to-date information, see the AWS Documentation.
You must have a Red Hat account with Cloud Administrator permissions to complete the integration.
3.1. Initiate the AWS integration process Copy linkLink copied to clipboard!
Add an AWS integration to enable cost management to process your AWS Cost and Usage Reports and provide visibility into your cloud spending patterns.
Prerequisites
- You must have a Red Hat Hybrid Cloud Console service account.
- To add data integrations to cost management, you must have a Red Hat account with Cloud Administrator permissions.
Procedure
-
From Red Hat Hybrid Cloud Console, click Settings
> Integrations.
-
On the Settings page, click
to enter the Add a cloud integration wizard. - On the Select cloud provider step, select Amazon Web Services. Click Next.
- Enter a name for the integration and click Next.
- On the Select configuration step, select Manual configuration. Do not select the recommended configuration mode when you configure cost management integrations. The recommendation is for other workflows.
- In the Select application step, select Cost management. Click Next.
3.2. Configure AWS storage for cost data exports Copy linkLink copied to clipboard!
Create a data export and configure an Amazon S3 bucket with permissions enabled to store your AWS billing data for cost management analysis.
Procedure
- Log in to your AWS account.
- In the AWS S3 console, create a new S3 bucket or use an existing bucket. If you are configuring a new S3 bucket, accept the default settings.
- In the cost management Add an integration wizard, enter the name of your S3 bucket and select the region that it was created in. Click Next.
In Billing and Cost Management, create a data export to deliver to your S3 bucket. Enter the following values and accept the defaults for any other values:
- Export details: Legacy CUR export
- Export name: koku
- Select the Include resource IDs checkbox
- Time unit: Hourly
- Report data integration: Amazon Redshift and Amazon QuickSight. Disable report data integration for Amazon Athena.
- Compression type: GZIP
- S3 bucket: <the S3 bucket that you configured previously>
- S3 path prefix: cost
In the Add a cloud integration wizard, on the Create cost and usage report step, click Next.
NoteFor more details on configuration, see the AWS Billing and Cost Management documentation.
3.3. Import tags to organize cost data Copy linkLink copied to clipboard!
Activate your tags in AWS and then give cost management permissions to import them automatically. Tags can help you organize your AWS resources in cost management.
For more information about tagging, see Adding tags to an AWS resource.
Procedure
- In the AWS Billing console, click Cost Allocation Tags.
Select the tags that you want to use in cost management. Click Activate.
-
If your organization is converting systems from CentOS 7 to RHEL and using hourly billing, activate the
com_redhat_rheltag for your systems.
-
If your organization is converting systems from CentOS 7 to RHEL and using hourly billing, activate the
3.4. Grant secure access to AWS Cost and Usage Reports Copy linkLink copied to clipboard!
Create an IAM policy and role in AWS to grant cost management secure, read-only access to your AWS Cost and Usage Reports for billing analysis.
Procedure
In the cost management Add a cloud integration wizard, on the Tags, aliases, and organizational units step, select any additional data points that you want to include, then click Next:
-
Select Include AWS account aliases to display an AWS account alias rather than an account number. In the next step of the wizard, this selection populates
iam:ListAccountAliasesin your IAM JSON policy. -
Select Include AWS organization units if you are using consolidated billing rather than the account ID. In the next step of the wizard, this selection populates
_organization:List*_and_organizations:Describe*_in your IAM JSON policy.
-
Select Include AWS account aliases to display an AWS account alias rather than an account number. In the next step of the wizard, this selection populates
- Copy the IAM JSON policy that is generated based on your selections.
In the AWS Identity and Access Management console, create a new IAM policy:
Select the JSON tab and enter the IAM JSON policy that you copied from the Red Hat Hybrid Cloud Console Add a cloud integration wizard.
Example IAM JSON policy
{ "Version": "2012-10-17", "Statement": [ { "Sid": "VisualEditor0", "Effect": "Allow", "Action": [ "s3:ListBucket", "s3:GetObject" ], "Resource": [ "arn:aws:s3:::<your_bucket_name>", "arn:aws:s3:::<your_bucket_name>/*" ] }, { "Sid": "VisualEditor1", "Effect": "Allow", "Action": [ "cur:DescribeReportDefinitions", ], "Resource": "*" } ] }- Enter a name and create your policy.
Create a new IAM role:
- Select Another AWS account as the type of trusted entity.
- Enter 589173575009 for the Account ID to give Red Hat Hybrid Cloud Console read access to the AWS account’s cost data.
- In the cost management Add a cloud integration wizard, click Next, then copy your External ID from the Create IAM role step.
In the AWS Identity and Access Management console, complete the IAM role configuration:
- Enter your External ID.
- Attach the IAM policy that you configured.
- Enter a name and description to finish creating your role.
-
In Roles, open the summary screen for the role that you created, then copy the Role ARN (starts with
arn:aws:). - In the cost management Add a cloud integration wizard, click Next, enter your Role ARN, then click Next again.
- Review the details of your cloud integration and click Add.
Verification
Verify that Cost management can access Cost and Usage data from your AWS account and linked AWS accounts.
NoteThe data can take a few days to populate before it shows on the cost management dashboard.