The lamdab is to pull Pricing data for EC2 on demand and SP plus RDS On Demand.
This comes from the wellarchitectedlabs - 200_pricing_model_analysis but just as a terraformed version.
module "aws_tf_ec2_upgrade_reccomendation" {
source = "/aws_tf_rds_delete_unattached"
output_bucket = "mys3bucketname"
}
Once deployed you can use the athena to setup view from the crawlers to get the data in a nicer format. NOTE!! You must follow step 31 of this guide https://wellarchitectedlabs.com/cost/200_labs/200_pricing_model_analysis/1_pricing_sources/ to ensure the table is correct
| Name | Description | Type | Default | Required |
|---|---|---|---|---|
| output_bucket | Bucket name for the data to be loaded to | string | "" |
yes |
| pricing_cron | Rate expression for when to run the review of rds | string | "cron(0 6 ? * MON *)" |
no |
| env | Name of envirment | string | "" |
no |
Configure your AWS credentials using one of the supported methods for AWS CLI
tools, such as setting the
AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment variables. If you're using the ~/.aws/config file for profiles then export AWS_SDK_LOAD_CONFIG as "True".