Skip to content

feat: Add infrastructure cost optimization opportunity finder - #1220

Merged
BigBen-7 merged 1 commit into
PinSpace-Org:mainfrom
DevMuhdishaq:feat/DevBranch
Aug 31, 2026
Merged

feat: Add infrastructure cost optimization opportunity finder#1220
BigBen-7 merged 1 commit into
PinSpace-Org:mainfrom
DevMuhdishaq:feat/DevBranch

Conversation

@DevMuhdishaq

Copy link
Copy Markdown
Contributor

Closes #938

Summary

Adds a complete cost optimization framework that automatically identifies, prioritizes, and reports on cloud infrastructure cost savings opportunities. The system detects idle resources, over-provisioned instances, reserved instance opportunities, and savings plan recommendations.

Changes

  • Create infrastructure/scripts/find-optimizations.sh - Main scanning script that identifies cost optimization opportunities
  • Create infrastructure/scripts/generate-opportunity-report.py - Generates prioritized markdown reports from scan data
  • Create infrastructure/docs/cost-opportunities.md - Documentation and auto-generated report location
  • Add test data file to validate report generation

Key Features

  • Idle resource detection: Identifies running instances with <10% CPU utilization and unattached storage volumes
  • Over-provisioned instance detection: Analyzes CPU/memory usage to recommend rightsizing opportunities
  • Reserved Instance (RI) analysis: Calculates potential savings from purchasing RIs for steady-state workloads (37.5% savings vs on-demand)
  • Savings plan recommendations: Suggests optimal savings plan commitments for consistent compute and serverless spend
  • Prioritization: Ranks opportunities by impact (HIGH/MEDIUM/LOW) with clear implementation timelines
  • AWS-native integration: Works with AWS CLI out-of-the-box, includes simulation mode for other clouds
  • Multi-format output: Generates JSON, CSV, and markdown reports

Estimated Savings (Simulation Mode)

The framework identifies $685+ in potential monthly savings from the simulated scan, with high-priority items that deliver immediate value.

Testing

  • Verified script structure and report generation logic
  • Tested markdown report creation with sample data
  • Confirmed all files are in the correct locations as specified

Usage

# Make scripts executable
chmod +x ./infrastructure/scripts/find-optimizations.sh
chmod +x ./infrastructure/scripts/generate-opportunity-report.py

# Run full scan and generate reports
./infrastructure/scripts/find-optimizations.sh

Reports are automatically generated in:

@drips-wave

drips-wave Bot commented Aug 31, 2026

Copy link
Copy Markdown

@DevMuhdishaq Great news! 馃帀 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 馃殌

Learn more about application limits

@BigBen-7
BigBen-7 merged commit 30bd8d5 into PinSpace-Org:main Aug 31, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Build gist type distribution by urban vs rural Create infrastructure cost optimization opportunity finder

2 participants