Skip to content

Commit

Permalink
POL-1374 Email Cost Optimization Recommendations: Added Policy Support (
Browse files Browse the repository at this point in the history
#2709)

* update

* fix

* update

* fix

* update

* fix

* update

* update
  • Loading branch information
XOmniverse authored Oct 9, 2024
1 parent 846728b commit b370b67
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 11 deletions.
6 changes: 6 additions & 0 deletions cost/flexera/cco/email_recommendations/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## v0.6.0

- Added support for additional recommendation policy templates
- Changed "Disk" option to "Storage" for `Recommendation List` parameter to better reflect functionality
- Added "PaaS" option to `Recommendation List` parameter

## v0.5.0

- Added parameter `Always Email Incident` that forces incident to always be emailed if enabled
Expand Down
37 changes: 28 additions & 9 deletions cost/flexera/cco/email_recommendations/email_recommendations.pt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ severity "low"
category "Cost"
default_frequency "weekly"
info(
version: "0.5.0",
version: "0.6.0",
provider: "Flexera",
service: "Cloud Cost Optimization",
policy_set: "Cloud Cost Optimization"
Expand Down Expand Up @@ -73,8 +73,8 @@ parameter "param_recommendation_list" do
category "Filters"
label "Recommendation List"
description "The types of recommendations to include in the email."
allowed_values ["Compute", "Snapshot", "Database", "IP Address", "Disk", "Network", "Reservation", "Savings Plan"]
default ["Compute", "Snapshot", "Database", "IP Address", "Disk", "Network", "Reservation", "Savings Plan"]
allowed_values ["Compute", "Snapshot", "Database", "IP Address", "Storage", "Network", "PaaS", "Reservation", "Savings Plan"]
default ["Compute", "Snapshot", "Database", "IP Address", "Storage", "Network", "PaaS", "Reservation", "Savings Plan"]
end

parameter "param_policy_list" do
Expand Down Expand Up @@ -108,38 +108,57 @@ script "js_recommendation_types", type:"javascript" do
result "result"
code <<-'EOS'
result = {
"AWS EC2 Compute Optimizer Recommendations": "Compute",
"AWS Idle Compute Instances": "Compute",
"AWS Idle NAT Gateways": "Network",
"AWS Old Snapshots": "Snapshot",
"AWS Rightsize EBS Volumes": "Storage",
"AWS Rightsize EC2 Instances": "Compute",
"AWS Rightsize RDS Instances": "Database",
"AWS Rightsize EBS Volumes": "Disk",
"AWS Rightsize ElastiCache": "Database",
"AWS Rightsize Redshift": "Database",
"AWS Unused Application Load Balancers": "Network",
"AWS Unused Classic Load Balancers": "Network",
"AWS Unused Network Load Balancers": "Network",
"AWS Unused IP Addresses": "IP Address",
"AWS Unused RDS Instances": "Database",
"AWS Unused Volumes": "Disk",
"AWS Unused Volumes": "Storage",
"AWS Superseded EBS Volumes": "Storage",
"AWS Superseded EC2 Instances": "Compute",
"AWS Reserved Instances Recommendations": "Reservation",
"AWS Savings Plan Recommendations": "Savings Plan",
"Azure Databricks Rightsize Compute Instances": "Compute",
"Azure Hybrid Use Benefit for Windows Server": "Compute",
"Azure Hybrid Use Benefit for Linux Server": "Compute",
"Azure Hybrid Use Benefit for SQL": "Compute",
"Azure Idle Compute Instances": "Compute",
"Azure Old Snapshots": "Snapshot",
"Azure Rightsize Compute Instances": "Compute",
"Azure Rightsize Managed Disks": "Disk",
"Azure Rightsize NetApp Files": "Disk",
"Azure Rightsize Managed Disks": "Storage",
"Azure Rightsize MySQL Single Servers": "Database",
"Azure Rightsize MySQL Flexible Servers": "Database",
"Azure Rightsize NetApp Files": "Storage",
"Azure Rightsize NetApp Resources": "Storage",
"Azure Rightsize SQL Databases": "Database",
"Azure Rightsize SQL Database Storage": "Database",
"Azure Rightsize SQL Managed Instances": "Database",
"Azure Rightsize SQL Managed Instance Storage": "Database",
"Azure Rightsize Synapse SQL Pools": "Database",
"Azure Superseded Compute Instances": "Compute",
"Azure Unused App Service Plans": "PaaS",
"Azure Unused Firewalls": "Network",
"Azure Unused Load Balancers": "Network",
"Azure Unused IP Addresses": "IP Address",
"Azure Unused SQL Databases": "Database",
"Azure Unused Volumes": "Disk",
"Azure Unused Volumes": "Storage",
"Azure Reserved Instances Recommendations": "Reservation",
"Azure Savings Plan Recommendations": "Savings Plan",
"Google Idle Cloud SQL Instance Recommender": "Database",
"Google Idle IP Address Recommender": "IP Address",
"Google Idle Persistent Disk Recommender": "Disk",
"Google Idle Persistent Disk Recommender": "Storage",
"Google Idle VM Recommender": "Compute",
"Google Old Snapshots": "Snapshot",
"Google Rightsize Cloud SQL Recommender": "Database",
"Google Rightsize VM Recommender": "Compute",
"Google Committed Use Discount Recommender": "Reservation"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4664,7 +4664,7 @@
{
"id": "./cost/flexera/cco/email_recommendations/email_recommendations.pt",
"name": "Email Cost Optimization Recommendations",
"version": "0.5.0",
"version": "0.6.0",
"providers": [
{
"name": "flexera",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2696,7 +2696,7 @@
required: true
- id: "./cost/flexera/cco/email_recommendations/email_recommendations.pt"
name: Email Cost Optimization Recommendations
version: 0.5.0
version: 0.6.0
:providers:
- :name: flexera
:permissions:
Expand Down

0 comments on commit b370b67

Please sign in to comment.