{"id":50249234,"url":"https://github.com/tanrikuluozlem/burn","last_synced_at":"2026-06-12T16:00:31.374Z","repository":{"id":342550553,"uuid":"1173317917","full_name":"tanrikuluozlem/burn","owner":"tanrikuluozlem","description":"See what's burning your Kubernetes budget","archived":false,"fork":false,"pushed_at":"2026-06-08T08:33:25.000Z","size":1417,"stargazers_count":79,"open_issues_count":4,"forks_count":2,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-08T10:19:32.238Z","etag":null,"topics":["ai","aws","azure","cli","cost-optimization","finops","gcp","golang","k8s","kubernetes","prometheus","slack"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tanrikuluozlem.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-05T08:30:57.000Z","updated_at":"2026-06-08T08:33:29.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/tanrikuluozlem/burn","commit_stats":null,"previous_names":["tanrikuluozlem/burn"],"tags_count":18,"template":false,"template_full_name":null,"purl":"pkg:github/tanrikuluozlem/burn","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tanrikuluozlem%2Fburn","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tanrikuluozlem%2Fburn/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tanrikuluozlem%2Fburn/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tanrikuluozlem%2Fburn/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tanrikuluozlem","download_url":"https://codeload.github.com/tanrikuluozlem/burn/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tanrikuluozlem%2Fburn/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34251773,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-12T02:00:06.859Z","response_time":109,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","aws","azure","cli","cost-optimization","finops","gcp","golang","k8s","kubernetes","prometheus","slack"],"created_at":"2026-05-27T01:00:41.839Z","updated_at":"2026-06-12T16:00:31.365Z","avatar_url":"https://github.com/tanrikuluozlem.png","language":"Go","funding_links":[],"categories":["Cost \u0026 Governance"],"sub_categories":[],"readme":"# burn\n\n[![CI](https://github.com/tanrikuluozlem/burn/actions/workflows/ci.yml/badge.svg)](https://github.com/tanrikuluozlem/burn/actions/workflows/ci.yml)\n[![Release](https://img.shields.io/github/v/release/tanrikuluozlem/burn)](https://github.com/tanrikuluozlem/burn/releases)\n[![Go Report Card](https://goreportcard.com/badge/github.com/tanrikuluozlem/burn)](https://goreportcard.com/report/github.com/tanrikuluozlem/burn)\n[![License](https://img.shields.io/github/license/tanrikuluozlem/burn)](LICENSE)\n\nYour Kubernetes cluster is burning money. Find out where.\n\n![demo](assets/demo.gif)\n\nNo agent to deploy. No dashboard to maintain. No YAML to configure. Just install and run.\n\n[![Watch the demo](https://img.youtube.com/vi/uGVvaKXeTf4/maxresdefault.jpg)](https://youtu.be/uGVvaKXeTf4)\n\n## Why burn\n\n- **Zero setup** — `brew install`, run one command, get answers. No cluster agent, no persistent storage, no config files.\n- **Full cost coverage** — Compute, storage, load balancers, and GPU costs with real-time cloud pricing.\n- **AI-powered** — Ask questions in plain English, get kubectl commands you can copy-paste.\n- **Slack-native** — `/burn` for instant cost reports. `/burn ask \"...\"` for AI analysis.\n- **Cloud + on-prem** — Works with AWS EKS, Azure AKS, GCP GKE, and on-premise clusters.\n- **Spot readiness** — Identifies which workloads can safely move to spot instances with real-time discount and interruption rate.\n- **Ingress LB detection** — Detects load balancers from both Services and Ingress resources, with hostname deduplication.\n- **Time-aware** — `--period 7d` for weekly averages instead of point-in-time snapshots.\n\n## Install\n\n```bash\n# Homebrew\nbrew install tanrikuluozlem/burn/burn\n\n# Upgrade\nbrew upgrade tanrikuluozlem/burn/burn\n\n# Binary\nVERSION=$(curl -s https://api.github.com/repos/tanrikuluozlem/burn/releases/latest | grep tag_name | cut -d'\"' -f4 | tr -d 'v') \u0026\u0026 \\\ncurl -L \"https://github.com/tanrikuluozlem/burn/releases/latest/download/burn_${VERSION}_$(uname -s | tr '[:upper:]' '[:lower:]')_$(uname -m | sed 's/x86_64/amd64/;s/aarch64/arm64/').tar.gz\" | tar xz\n\n# Docker\ndocker pull ghcr.io/tanrikuluozlem/burn:latest\n\n# Helm\ngit clone https://github.com/tanrikuluozlem/burn.git\nhelm install burn ./burn/charts/burn\n\n# Go\ngo install github.com/tanrikuluozlem/burn/cmd/burn@latest\n```\n\n\u003e **macOS:** If you see a Gatekeeper warning, run: `sudo xattr -d com.apple.quarantine $(which burn)`\n\n## Quick start\n\n```bash\n# Cost breakdown (without Prometheus)\nburn analyze\n\n# With Prometheus (pass your Prometheus URL)\nburn analyze --prometheus http://prometheus:9090\n\n# 7-day average\nburn analyze --prometheus http://prometheus:9090 --period 7d\n\n# Drill into a namespace\nburn analyze --prometheus http://prometheus:9090 --namespace argocd\n\n# Spot readiness\nburn analyze --prometheus http://prometheus:9090 --spot\n```\n\n## Spot readiness\n\n![spot readiness](assets/demo-spot.gif)\n\nReal-time spot discount and interruption rate per instance type.\n\n## AI recommendations\n\nGet cluster-wide or namespace-specific recommendations:\n\n```bash\nburn analyze --prometheus http://prometheus:9090 --period 7d --ai\nburn analyze --prometheus http://prometheus:9090 --namespace app-backend --ai\nburn ask --prometheus http://prometheus:9090 \"why is argocd so expensive?\"\n```\n\nExample: `burn analyze --namespace app-backend --period 7d --ai`\n\n```\nNAMESPACE: app-backend (3 pods, $17.19/mo)\n──────────────────────────────────\nPOD                      CPU REQ→USED  MEM REQ→USED   COST/MO\napp-backend-deploy-0001  200m → \u003c1m    256Mi → 9Mi    $5.73\napp-backend-deploy-0002  200m → \u003c1m    256Mi → 9Mi    $5.73\napp-backend-deploy-0003  200m → \u003c1m    256Mi → 128Mi  $5.73\n\nRECOMMENDATIONS\n───────────────\nThe app-backend namespace costs $17.19/mo across 3 pods, but CPU efficiency\nis critically low at ~0.1% — pods request 200m CPU each while p95 usage\nis under 0.31m.\n\n[!!] 1. Rightsize CPU Requests using p95 data\n   app-backend-deploy-0001: p95 CPU is 0.22m → recommend 1m (1.5x p95)\n   app-backend-deploy-0002: p95 CPU is 0.30m → recommend 1m (1.5x p95)\n   app-backend-deploy-0003: p95 MEM is 128Mi (50% eff) — leave as-is\n   $ kubectl set resources deployment app-backend -n app-backend \\\n     --requests=cpu=1m,memory=14Mi --limits=cpu=200m,memory=256Mi\n\n[!!] 2. app-backend-ingress LB ($19.71/mo) costs more than the namespace\n   The load balancer alone exceeds the $17.19/mo compute cost.\n   If internal-only, switch to ClusterIP to eliminate the LB cost.\n   $ kubectl patch svc app-backend-ingress -n app-backend \\\n     -p '{\"spec\": {\"type\": \"ClusterIP\"}}'\n\n[!] 3. Enable VPA in Recommend Mode\n   Prevent over-provisioning from recurring with continuous p95 tracking.\n   $ kubectl apply -f vpa-app-backend.yaml\n```\n\n### Ask questions in plain English\n\n![ask demo](assets/demo-ask.gif)\n\nRequires `ANTHROPIC_API_KEY` environment variable.\n\n## Slack integration\n\nRun burn as a Slack bot:\n\n```bash\nburn serve --port 8080 --prometheus http://prometheus:9090 --period 7d\n```\n\n| Command | What you get |\n|---------|-------------|\n| `/burn` | Full cost report — nodes, namespaces, idle cost, LB, storage |\n| `/burn ns argocd` | Pod-level breakdown for a namespace |\n| `/burn ask \"what is the single biggest waste?\"` | AI analysis with kubectl commands |\n\n![Slack AI](assets/slack-ask.png)\n\n### Slack setup\n\n1. Create a Slack App at https://api.slack.com/apps\n2. Add Slash Command: `/burn` → point to your server URL + `/slack`\n3. Set `SLACK_SIGNING_SECRET` and `ANTHROPIC_API_KEY` environment variables\n4. Expose the server (e.g., ngrok for testing, load balancer for production)\n\n## On-prem and GPU clusters\n\nBurn works with on-premise and GPU clusters. Set your own resource rates:\n\n```bash\nburn analyze \\\n  --cpu-price 0.05 \\\n  --ram-price 0.008 \\\n  --gpu-price 3.00 \\\n  --storage-price 0.10\n```\n\nWithout custom pricing, cloud-equivalent rates are used as defaults.\n\n## How it works\n\n```\nKubernetes API → nodes, pods, PVCs, services, ingresses\nPrometheus     → actual CPU \u0026 memory usage (optional)\nCloud Pricing  → real VM, storage, and GPU prices (AWS, Azure, GCP)\n         ↓\n    Cost Engine → compute, storage, load balancers, GPU, idle detection\n         ↓\n    CLI / Slack / AI Recommendations\n```\n\n### Pricing sources\n\n| Priority | Source | When |\n|----------|--------|------|\n| 1 | AWS/Azure pricing API | AWS credentials available — real-time, region-aware |\n| 2 | Embedded pricing DB | No credentials — 600+ AWS, 300+ Azure instances, updated weekly |\n| 3 | Static fallback | Unknown instance type — estimates based on instance family |\n\nStorage and load balancer costs are fetched from cloud APIs when available, with static fallbacks. Usage-based charges (data processing, LCU) depend on traffic volume and are not included. GPU nodes are detected automatically and priced via ratio-based cost splitting.\n\n## Deploy to Kubernetes\n\n### Helm\n\n```bash\ngit clone https://github.com/tanrikuluozlem/burn.git\nhelm install burn ./burn/charts/burn \\\n  --set prometheus.url=http://prometheus:9090 \\\n  --set schedule=\"0 9 * * 1-5\"\n```\n\n### CronJob (daily Slack reports)\n\n```yaml\napiVersion: batch/v1\nkind: CronJob\nmetadata:\n  name: burn-report\nspec:\n  schedule: \"0 9 * * 1-5\"\n  jobTemplate:\n    spec:\n      template:\n        spec:\n          containers:\n          - name: burn\n            image: ghcr.io/tanrikuluozlem/burn:latest\n            args:\n            - analyze\n            - --prometheus\n            - http://prometheus-server.monitoring:80\n            - --period\n            - 7d\n            - --ai\n            - --slack\n            env:\n            - name: ANTHROPIC_API_KEY\n              valueFrom:\n                secretKeyRef:\n                  name: burn-secrets\n                  key: anthropic-api-key\n            - name: SLACK_WEBHOOK_URL\n              valueFrom:\n                secretKeyRef:\n                  name: burn-secrets\n                  key: slack-webhook-url\n          restartPolicy: OnFailure\n```\n\n## Configuration\n\n| Variable | Description | Required for |\n|----------|-------------|-------------|\n| `ANTHROPIC_API_KEY` | Claude API key | `--ai`, `ask`, `serve` |\n| `SLACK_WEBHOOK_URL` | Slack webhook URL | `--slack` |\n| `SLACK_SIGNING_SECRET` | Slack app signing secret | `serve` |\n\n| Flag | Description |\n|------|-------------|\n| `--cpu-price` | CPU cost per core per hour (on-prem) |\n| `--ram-price` | RAM cost per GiB per hour (on-prem) |\n| `--gpu-price` | GPU cost per unit per hour (on-prem) |\n| `--storage-price` | Storage cost per GiB per month (on-prem) |\n| `--spot` | Show spot instance readiness details |\n\nCloud clusters use real pricing automatically. These flags are for on-premise clusters where pricing is not available from a cloud provider.\n\n## Development\n\n```bash\nmake build    # Build binary\nmake test     # Run tests\nmake lint     # Run linter\n```\n\n## License\n\nApache 2.0 — See [LICENSE](LICENSE) for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftanrikuluozlem%2Fburn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftanrikuluozlem%2Fburn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftanrikuluozlem%2Fburn/lists"}