CloudBurn Logo
CloudBurnHome
  • Cost estimation

    • AWS Simple Pricing CalculatorEstimate your AWS stack
    • IaC Cost EstimatorReview costs before merge

    Cost analysis

    • AWS Cost TreeSee where your spend went

    Cost Optimization

    • Unused resourcesFind resources to remove
    • Resource efficiencyImprove what you keep
    • Commitment savingsReview plans and reservations
    • Cost GovernanceBudgets, alerts, and tags

    Product

    • RoadmapWhat's coming next
    • ChangelogProduct updates
    • DocsGuides and reference
    • AboutWhy CloudBurn exists
  • Pricing
  • Blog
  • Tools
Join the CloudBurn Discord community
Join the waitlistWaitlist
Join the CloudBurn Discord community1.8k
Navigation
    • Overview
    • Installation
    • Configuration
    • GitHub Action
    • MCP Plugin
    • VS Code Extension
      • Scan IaC Files
      • Discover AWS
      • scan
      • discover
      • config
      • rules list
      • completion
      • estimate
      • Exit Codes
      • Output Formats
      • CI/CD Integration
      • Resource Explorer Setup
    • Overview
    • Connect an AWS Account
    • Set Up PR Cost Estimation
    • Plans and Billing
    • Workspaces and Members
    • AWS Cost Tree
      • Usage Assumptions
      • Examples
      • Unused Resources
      • Resource Efficiency
      • Commitment Savings
      • Cost Governance
    • Overview
    • Understanding Rules
      • CloudFront
      • CloudTrail
      • CloudWatch
      • AWS Config
      • Cost Explorer
      • Cost Guardrails
      • Cost Optimization Hub
      • DynamoDB
      • EBS
      • EC2
      • ECR
      • ECS
      • EKS
      • ElastiCache
      • ELB
      • EMR
      • KMS
      • Lambda
      • RDS
      • Redshift
      • Route 53
      • S3
      • SageMaker
      • Secrets Manager
      • Tagging
    • Overview
    • Installation
      • Static IaC Scan
      • Discovery Scan
      • CloudBurnClient
      • Types
      • Package Exports
      • Custom Config
      • AWS Credentials
    • Overview
    • Installation
    • Configuration
    • GitHub Action
    • MCP Plugin
    • VS Code Extension
      • Scan IaC Files
      • Discover AWS
      • scan
      • discover
      • config
      • rules list
      • completion
      • estimate
      • Exit Codes
      • Output Formats
      • CI/CD Integration
      • Resource Explorer Setup
    • Overview
    • Connect an AWS Account
    • Set Up PR Cost Estimation
    • Plans and Billing
    • Workspaces and Members
    • AWS Cost Tree
      • Usage Assumptions
      • Examples
      • Unused Resources
      • Resource Efficiency
      • Commitment Savings
      • Cost Governance
    • Overview
    • Understanding Rules
      • CloudFront
      • CloudTrail
      • CloudWatch
      • AWS Config
      • Cost Explorer
      • Cost Guardrails
      • Cost Optimization Hub
      • DynamoDB
      • EBS
      • EC2
      • ECR
      • ECS
      • EKS
      • ElastiCache
      • ELB
      • EMR
      • KMS
      • Lambda
      • RDS
      • Redshift
      • Route 53
      • S3
      • SageMaker
      • Secrets Manager
      • Tagging
    • Overview
    • Installation
      • Static IaC Scan
      • Discovery Scan
      • CloudBurnClient
      • Types
      • Package Exports
      • Custom Config
      • AWS Credentials
Loading documentation page
CloudBurn Logo
CloudBurn

Open-source AWS cost checks and an upcoming platform for cost estimation, optimization, and governance.

1.8k

Product

  • Pricing
  • Roadmap
  • Changelog
  • About
  • Blog
  • Waitlist
  • Docs
  • Contact

Free Tools

  • EC2 Pricing Calculator
  • S3 Pricing Calculator
  • Bedrock Pricing Calculator
  • Fargate Pricing Calculator
  • RDS Pricing Calculator
  • ECS Pricing Calculator
  • Aurora Pricing Calculator
  • All AWS pricing calculators →

CloudBurn Platform · early 2027

Price changes before you deploy. Fix the waste after.

Join now for 30% off, for as long as you keep your plan.

Join the waitlist

Two emails a month at most. Unsubscribe anytime. By signing up you agree to the privacy policy.

CloudBurn © 2026 | Terms & Privacy

Built with ❤️ by Towards the Cloud

  • Pricing
  • Blog
  • Tools
      • Overview
      • Installation
      • Configuration
      • GitHub Action
      • MCP Plugin
      • VS Code Extension
        • scan
        • discover
        • config
        • rules list
        • completion
        • estimate
      • Overview
      • Installation
      • Configuration
      • GitHub Action
      • MCP Plugin
      • VS Code Extension
        • scan
        • discover
        • config
        • rules list
        • completion
        • estimate
    CloudBurn CLI

    cloudburn scan

    Run cloudburn scan on Terraform and CloudFormation files to find AWS cost issues before deployment. Review flags, output formats, and CI policy gate options.

    Synopsis

    cloudburn scan [path] [flags]
    

    Description

    Runs a static analysis scan against Terraform (.tf) and CloudFormation (.json, .yaml, .yml) files. CloudBurn auto-detects file types — you don't need to specify which IaC format you're using.

    When no [path] is provided, CloudBurn scans the current working directory recursively.

    Arguments

    ArgumentDescription
    [path]Optional. Directory or file to scan. Defaults to the current working directory.

    Flags

    FlagTypeDefaultDescription
    --configstringauto-discoveryPath to a .cloudburn.yml config file. Required to apply config in CI — see CI environments.
    --enabled-rulesstringAWS Core presetComma-separated list of rule IDs to include. Replaces the AWS Core preset for this scan.
    --disabled-rulesstringnoneComma-separated list of rule IDs to exclude from the selected set — the AWS Core preset, or your enabled-rules list when one is set.
    --servicestringall servicesComma-separated list of services to scan (e.g. ebs,ec2).
    --exit-codebooleanfalseExit with code 1 when any active finding exists. Useful for CI gates.
    --fail-onstringnoneExit with code 1 when an active finding meets or exceeds this severity: high, medium, or low. Can also be set as iac.fail-on in config.

    By default, CloudBurn runs the AWS Core preset for the mode you use, which excludes the opt-in rules that need AWS-side setup. Those rules are all discovery-only, so they apply to cloudburn discover, not to static scans — config validation rejects rules that do not support the current scan mode. See Rules for the full catalog.

    Suppressing findings inline

    Terraform and CloudFormation YAML support resource-local exceptions. Put one of these comments immediately above or inside the resource; text after the directive is retained as an optional reason:

    # cloudburn-ignore CLDBRN-AWS-EBS-1 migration scheduled
    resource "aws_ebs_volume" "legacy" {
      type = "gp2"
    }
    
    # cloudburn-ignore-all approved temporary exception
    resource "aws_ebs_volume" "temporary" {
      type = "gp2"
    }
    

    cloudburn-ignore <rule-id> [reason] suppresses a single rule for the annotated resource. cloudburn-ignore-all [reason] suppresses every rule for that resource. Suppressed findings stay visible in JSON output under suppressed, are counted in table output, and never fail --exit-code or --fail-on gates. CloudFormation JSON does not support comments and therefore cannot carry inline suppressions — use CloudFormation YAML or disabled-rules instead.

    Exit codes

    cloudburn scan exits 0 when no finding trips a gate, 1 when an active finding satisfies --exit-code or --fail-on, and 2 on runtime or usage errors such as a missing path or invalid config. The Exit codes guide has the full contract, including how suppressed findings interact with gates.

    Examples

    Scan the current directory:

    cloudburn scan
    

    Scan a specific path:

    cloudburn scan ./infrastructure
    

    Scan only EBS rules and fail CI on any finding:

    cloudburn scan --service ebs --exit-code
    

    Fail CI only on high-severity findings:

    cloudburn scan --fail-on high
    

    Output as JSON:

    cloudburn --format json scan ./iac
    

    Run only specific rules:

    cloudburn scan --enabled-rules CLDBRN-AWS-EBS-1,CLDBRN-AWS-EC2-2
    

    Use a non-default config file (required in CI to apply its rule selection, output defaults, or severity gate):

    cloudburn scan --config ./configs/.cloudburn.yml
    

    Example JSON output structure (the raw ScanResult object is serialized directly):

    {
      "providers": [
        {
          "provider": "aws",
          "rules": [
            {
              "ruleId": "CLDBRN-AWS-EBS-1",
              "service": "ebs",
              "severity": "medium",
              "source": "iac",
              "message": "EBS volumes should use current-generation storage.",
              "findings": [
                {
                  "resourceId": "aws_ebs_volume.main",
                  "location": {
                    "path": "modules/storage/main.tf",
                    "line": 12,
                    "column": 1
                  }
                }
              ]
            }
          ]
        }
      ]
    }
    

    When any finding is suppressed by an inline cloudburn-ignore comment, the JSON result also carries a top-level suppressed array. A config-file severity gate can populate policy, but explicit --fail-on and --exit-code flags are applied after serialization and do not replace that JSON field. Use the exit code for the final CLI gate verdict:

    {
      "providers": [],
      "suppressed": [
        {
          "provider": "aws",
          "ruleId": "CLDBRN-AWS-EBS-1",
          "service": "ebs",
          "severity": "medium",
          "source": "iac",
          "message": "EBS volumes should use current-generation storage.",
          "finding": {
            "resourceId": "aws_ebs_volume.legacy",
            "location": { "path": "modules/storage/main.tf", "line": 12, "column": 1 }
          },
          "suppression": { "kind": "rule", "ruleId": "CLDBRN-AWS-EBS-1", "reason": "migration scheduled", "location": { "path": "modules/storage/main.tf", "line": 11, "column": 1 } }
        }
      ]
    }
    

    Rules

    Rules evaluated by this scan are documented in Rules.

    What's next

    ConfigurationSet default flags in .cloudburn.yml
    Exit CodesUse exit codes in CI/CD pipelines
    CI/CD IntegrationFull GitHub Actions and GitLab CI examples
    ← PreviousDiscover AWSNext →discover

    CloudBurn Platform · early 2027

    Price changes before you deploy. Fix the waste after.

    Join now for 30% off, for as long as you keep your plan.

    Join the waitlist

    Two emails a month at most. Unsubscribe anytime. By signing up you agree to the privacy policy.